satorijs / qq-guild-sdk

https://satori.js.org/qq-guild-sdk/
MIT License
29 stars 3 forks source link

表示不会搞 #1

Closed SaucePlum closed 2 years ago

SaucePlum commented 2 years ago

image

NWYLZW commented 2 years ago

在你的 package.json 指定 type: "module" 或者将你的文件后缀修改为 .mjs 或者使用 commonjs 的 require api,require('qq-guild-sdk').createBot|Bot

SaucePlum commented 2 years ago

能写一份cil已构建好可以运行的文件给我嘛

---原始邮件--- 发件人: @.> 发送时间: 2022年2月22日(周二) 下午2:08 收件人: @.>; 抄送: @.**@.>; 主题: Re: [NWYLZW/qq-guild-sdk] 表示不会搞 (Issue #1)

在你的 package.json 指定 type: "module" 或者将你的文件后缀修改为 .mjs 或者使用 commonjs 的 require api,require('qq-guild-sdk').createBot|Bot

— Reply to this email directly, view it on GitHub, or unsubscribe. Triage notifications on the go with GitHub Mobile for iOS or Android. You are receiving this because you authored the thread.Message ID: @.***>

NWYLZW commented 2 years ago

能写一份cil已构建好可以运行的文件给我嘛 ---原始邮件--- 发件人: @.> 发送时间: 2022年2月22日(周二) 下午2:08 收件人: @.>; 抄送: @.**@.>; 主题: Re: [NWYLZW/qq-guild-sdk] 表示不会搞 (Issue #1) 在你的 package.json 指定 type: "module" 或者将你的文件后缀修改为 .mjs 或者使用 commonjs 的 require api,require('qq-guild-sdk').createBot|Bot — Reply to this email directly, view it on GitHub, or unsubscribe. Triage notifications on the go with GitHub Mobile for iOS or Android. You are receiving this because you authored the thread.Message ID: @.***>

就照着上面改一下就行啦,不麻烦的

SaucePlum commented 2 years ago

改了还是不行呀

---原始邮件--- 发件人: @.> 发送时间: 2022年2月23日(周三) 上午9:52 收件人: @.>; 抄送: @.**@.>; 主题: Re: [NWYLZW/qq-guild-sdk] 表示不会搞 (Issue #1)

能写一份cil已构建好可以运行的文件给我嘛 … ---原始邮件--- 发件人: @.> 发送时间: 2022年2月22日(周二) 下午2:08 收件人: @.>; 抄送: @.@.>; 主题: Re: [NWYLZW/qq-guild-sdk] 表示不会搞 (Issue #1) 在你的 package.json 指定 type: "module" 或者将你的文件后缀修改为 .mjs 或者使用 commonjs 的 require api,require('qq-guild-sdk').createBot|Bot — Reply to this email directly, view it on GitHub, or unsubscribe. Triage notifications on the go with GitHub Mobile for iOS or Android. You are receiving this because you authored the thread.Message ID: @.***>

就照着上面改一下就行啦,不麻烦的

— Reply to this email directly, view it on GitHub, or unsubscribe. Triage notifications on the go with GitHub Mobile for iOS or Android. You are receiving this because you authored the thread.Message ID: @.***>

NWYLZW commented 2 years ago
image

看起来是 nodejs 对 modulejs 的解构不支持,你试着把 index.js 上方的改成这个格式 具体原因我还得研究一下

NWYLZW commented 2 years ago

我刚刚试了这样写是能够运行了

SaucePlum commented 2 years ago

跑起来了,是否沙箱模式在哪设置啊

---原始邮件--- 发件人: @.> 发送时间: 2022年2月23日(周三) 上午10:27 收件人: @.>; 抄送: @.**@.>; 主题: Re: [NWYLZW/qq-guild-sdk] 表示不会搞 (Issue #1)

我刚刚试了这样写是能够运行了

— Reply to this email directly, view it on GitHub, or unsubscribe. Triage notifications on the go with GitHub Mobile for iOS or Android. You are receiving this because you authored the thread.Message ID: @.***>

NWYLZW commented 2 years ago

https://nwylzw.github.io/qq-guild-sdk/api/core/Bot.html#bot-options 可查阅文档,默认开启((((大概