mirror of
https://github.com/discordjs/discord.js.git
synced 2026-03-09 16:13:31 +01:00
chore(build): disable tsup minification & add "use strict"; banner to CJS bundles (#7725)
* chore(build): disable tsup minification * chore(build): add `"use strict";` to CJS bundles
This commit is contained in:
@@ -5,9 +5,16 @@ export const tsup: Options = {
|
||||
dts: false,
|
||||
entryPoints: ['src/index.ts'],
|
||||
format: ['esm', 'cjs'],
|
||||
minify: true,
|
||||
minify: false,
|
||||
keepNames: true,
|
||||
skipNodeModulesBundle: true,
|
||||
sourcemap: true,
|
||||
target: 'es2021',
|
||||
esbuildOptions: (options, context) => {
|
||||
if (context.format === 'cjs') {
|
||||
options.banner = {
|
||||
js: '"use strict";',
|
||||
};
|
||||
}
|
||||
},
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user