Open clown-q opened 1 month ago
编译完成之后scripts
文件夹是不是空的
如果是这就是一个已知问题,tsc在编译时会莫名其妙地在路径后加一个\n
并导致编译失败,这个\n
不清楚是哪步被加入的,node侧进行的任何处理都无法去除,所以编译TS可能产生空的scripts目录。后续考虑使用esbuild替换tsc来尝试解决此问题。
临时解决方案(二选一):
npx -p typescript tsc --build
并输入yes
手动编译,随后再运行toolbox删除ts文件我使用第一种临时解决了上面的问题,感谢
在开始之前......
assignees
问题发生位置
Hexo渲染报错
问题描述
Unhandled rejection TypeError: F:\blog\themes\shokax\layout_partials\layout.pug:9 7| - ignores.push(theme.quicklink.ignores) 8|
_cover_index is not a function at eval (eval at wrap (F:\blog_clown\node_modules.pnpm\pug-runtime@3.0.1\node_modules\pug-runtime\wrap.js:6:10),:631:14)
at template (eval at wrap (F:\blog_clown\node_modules.pnpm\pug-runtime@3.0.1\node_modules\pug-runtime\wrap.js:6:10), :1187:7)
at _View._compiled (F:\blog_clown\node_modules.pnpm\hexo@7.3.0_chokidar@3.6.0\node_modules\hexo\dist\theme\view.js:120:67)
at _View.render (F:\blog_clown\node_modules.pnpm\hexo@7.3.0_chokidar@3.6.0\node_modules\hexo\dist\theme\view.js:37:21)
at F:\blog_clown\node_modules.pnpm\hexo@7.3.0_chokidar@3.6.0\node_modules\hexo\dist\hexo\index.js:60:29
at tryCatcher (F:\blog_clown\node_modules.pnpm\bluebird@3.7.2\node_modules\bluebird\js\release\util.js:16:23)
at F:\blog_clown\node_modules.pnpm\bluebird@3.7.2\node_modules\bluebird\js\release\method.js:15:34
at RouteStream._read (F:\blog_clown\node_modules.pnpm\hexo@7.3.0_chokidar@3.6.0\nodemodules\hexo\dist\hexo\router.js:43:9)
at Readable.read (node:internal/streams/readable:496:12)
at resume (node:internal/streams/readable:999:12)
at process.processTicksAndRejections (node:internal/process/task_queues:82:21)
复现步骤
cd themes git clone https://github.com/theme-shoka-x/hexo-theme-shokaX.git cd shokax node ./toolbox/compiler.mjs cd ../.. hexo s
相关配置
No response
注意事项