(WIP) Switch the rest of the build setup to esbuild - done
This commit is contained in:
parent
7c2e12c233
commit
b2d1f15446
1 changed files with 4 additions and 1 deletions
|
@ -5,12 +5,15 @@ for (const which of ['core', 'studio']) {
|
||||||
const pathToPackage = path.join(__dirname, '../', which)
|
const pathToPackage = path.join(__dirname, '../', which)
|
||||||
const esbuildConfig = {
|
const esbuildConfig = {
|
||||||
entryPoints: [path.join(pathToPackage, 'src/index.ts')],
|
entryPoints: [path.join(pathToPackage, 'src/index.ts')],
|
||||||
target: ['firefox88'],
|
target: ['firefox88', 'chrome90'],
|
||||||
loader: {'.png': 'file'},
|
loader: {'.png': 'file'},
|
||||||
outfile: path.join(pathToPackage, 'dist/index.js'),
|
outfile: path.join(pathToPackage, 'dist/index.js'),
|
||||||
bundle: true,
|
bundle: true,
|
||||||
sourcemap: true,
|
sourcemap: true,
|
||||||
define: definedGlobals,
|
define: definedGlobals,
|
||||||
}
|
}
|
||||||
|
if (which === 'core') {
|
||||||
|
esbuildConfig.target = ['firefox57', 'chrome58']
|
||||||
|
}
|
||||||
require('esbuild').build(esbuildConfig)
|
require('esbuild').build(esbuildConfig)
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue