mirror of
https://github.com/qlik-oss/nebula.js.git
synced 2025-12-19 09:48:18 -05:00
chore: fix mixin and external mod (#1817)
* chore: fix mixin and external mod * chore: add back to root * chore: add systemjs build of stardust * chore: trigger diff * fix: remove typo import
This commit is contained in:
@@ -94,6 +94,7 @@ const config = ({ format = 'umd', debug = false, file, targetPkg }) => {
|
||||
|
||||
// peers that are not devDeps should be externals for full bundle
|
||||
// const bundleExternals = peers.filter((p) => typeof (pkg.devDependencies || {})[p] === 'undefined');
|
||||
const useDirectoryOutput = format === 'systemjs';
|
||||
|
||||
const external = peers;
|
||||
const globals = {};
|
||||
@@ -123,17 +124,28 @@ const config = ({ format = 'umd', debug = false, file, targetPkg }) => {
|
||||
warn(warning);
|
||||
},
|
||||
input: path.resolve(cwd, 'src', 'index'),
|
||||
output: {
|
||||
// file: path.resolve(targetDir, getFileName(isEsm ? 'esm' : '', dev)),
|
||||
file,
|
||||
format,
|
||||
exports: ['test-utils', 'stardust'].indexOf(targetName) !== -1 ? 'named' : 'default',
|
||||
name: umdName,
|
||||
sourcemap: true,
|
||||
banner,
|
||||
globals,
|
||||
inlineDynamicImports: true,
|
||||
},
|
||||
output: useDirectoryOutput
|
||||
? {
|
||||
dir: path.dirname(file),
|
||||
entryFileNames: path.basename(file),
|
||||
chunkFileNames: 'chunks/[name]-[hash].js',
|
||||
format,
|
||||
exports: ['test-utils', 'stardust'].indexOf(targetName) !== -1 ? 'named' : 'default',
|
||||
sourcemap: true,
|
||||
banner,
|
||||
globals,
|
||||
inlineDynamicImports: false,
|
||||
}
|
||||
: {
|
||||
file,
|
||||
format,
|
||||
exports: ['test-utils', 'stardust'].indexOf(targetName) !== -1 ? 'named' : 'default',
|
||||
name: umdName,
|
||||
sourcemap: true,
|
||||
banner,
|
||||
globals,
|
||||
inlineDynamicImports: true,
|
||||
},
|
||||
external,
|
||||
plugins: [
|
||||
replace({
|
||||
@@ -227,6 +239,23 @@ let dist = [
|
||||
})
|
||||
: false,
|
||||
|
||||
targetName === 'stardust'
|
||||
? config({
|
||||
format: 'systemjs',
|
||||
targetPkg: pkg,
|
||||
file: path.resolve(targetDir, getFileName('systemjs', false)),
|
||||
})
|
||||
: false,
|
||||
|
||||
targetName === 'stardust'
|
||||
? config({
|
||||
debug: true,
|
||||
format: 'systemjs',
|
||||
targetPkg: pkg,
|
||||
file: path.resolve(targetDir, getFileName('systemjs', true)),
|
||||
})
|
||||
: false,
|
||||
|
||||
// core esm
|
||||
corePkg && corePkg.module
|
||||
? config({
|
||||
|
||||
Reference in New Issue
Block a user