Update build.js

This commit is contained in:
syuilo 2025-11-27 15:46:21 +09:00
parent 83cdef298b
commit c770a1746d
1 changed files with 3 additions and 0 deletions

View File

@ -18,6 +18,9 @@ const options = {
platform: 'node', platform: 'node',
format: 'esm', format: 'esm',
sourcemap: false, sourcemap: false,
banner: {
js: 'import { createRequire as topLevelCreateRequire } from "module"; import ___url___ from "url"; const require = topLevelCreateRequire(import.meta.url); const __filename = ___url___.fileURLToPath(import.meta.url); const __dirname = ___url___.fileURLToPath(new URL(".", import.meta.url));',
},
external: [ external: [
'*.node', '*.node',
'*.html', '*.html',