From c26aae8ec7074df49c56f8459af0d5563b46d04d Mon Sep 17 00:00:00 2001 From: Li Jin Date: Wed, 29 Jan 2025 14:19:15 +0800 Subject: Updated spec and docs. --- doc/docs/doc/README.md | 3 ++- doc/docs/zh/doc/README.md | 3 ++- 2 files changed, 4 insertions(+), 2 deletions(-) (limited to 'doc') diff --git a/doc/docs/doc/README.md b/doc/docs/doc/README.md index 49be707..7968a09 100755 --- a/doc/docs/doc/README.md +++ b/doc/docs/doc/README.md @@ -137,8 +137,9 @@ require("yue")("your_yuescript_entry") Require YueScript module and rewite message by hand. ```lua local yue = require("yue") +yue.insert_loader() local success, result = xpcall(function() - yue.require("yuescript_module_name") + require("yuescript_module_name") end, function(err) return yue.traceback(err) end) diff --git a/doc/docs/zh/doc/README.md b/doc/docs/zh/doc/README.md index be31ec1..882417e 100755 --- a/doc/docs/zh/doc/README.md +++ b/doc/docs/zh/doc/README.md @@ -137,8 +137,9 @@ require("yue")("你的脚本入口文件") 手动引入月之脚本模块并重写错误消息来帮助调试。 ```lua local yue = require("yue") +yue.insert_loaders() local success, result = xpcall(function() - yue.require("yuescript_module_name") + require("yuescript_module_name") end, function(err) return yue.traceback(err) end) -- cgit v1.2.3-55-g6feb