mirror of
https://github.com/qlik-oss/nebula.js.git
synced 2025-12-19 17:58:43 -05:00
fix: support qlik/api (#1789)
This commit is contained in:
@@ -67,7 +67,7 @@ const config = ({
|
|||||||
mode = 'production',
|
mode = 'production',
|
||||||
format = 'umd',
|
format = 'umd',
|
||||||
cwd = process.cwd(),
|
cwd = process.cwd(),
|
||||||
argv = { sourcemap: true, codeSplit: false },
|
argv = { sourcemap: true, codeSplit: false, inlineDynamic: false },
|
||||||
core,
|
core,
|
||||||
behaviours: {
|
behaviours: {
|
||||||
getExternal = getExternalDefault,
|
getExternal = getExternalDefault,
|
||||||
@@ -134,7 +134,7 @@ const config = ({
|
|||||||
} else {
|
} else {
|
||||||
outputConfig.dir = path.resolve(dir, outputFile.split('/')[0]);
|
outputConfig.dir = path.resolve(dir, outputFile.split('/')[0]);
|
||||||
}
|
}
|
||||||
if (format === 'umd') {
|
if (format === 'umd' || argv.inlineDynamic) {
|
||||||
outputConfig.inlineDynamicImports = true;
|
outputConfig.inlineDynamicImports = true;
|
||||||
}
|
}
|
||||||
return outputConfig;
|
return outputConfig;
|
||||||
|
|||||||
@@ -60,6 +60,11 @@ const options = {
|
|||||||
type: 'boolean',
|
type: 'boolean',
|
||||||
default: false,
|
default: false,
|
||||||
},
|
},
|
||||||
|
inlineDynamic: {
|
||||||
|
description: 'Sets inlineDynamicImports to true for all builds to help with certain dependencies',
|
||||||
|
type: 'boolean',
|
||||||
|
default: false,
|
||||||
|
},
|
||||||
};
|
};
|
||||||
|
|
||||||
// nebula build --watch - watch umd bundle
|
// nebula build --watch - watch umd bundle
|
||||||
|
|||||||
@@ -7,7 +7,6 @@ const systemjsBehaviours = {
|
|||||||
'react',
|
'react',
|
||||||
'react-dom',
|
'react-dom',
|
||||||
/^(?!@qlik-trial\/qmfe-data-client-parcels)(@qlik-trial\/qmfe-)/,
|
/^(?!@qlik-trial\/qmfe-data-client-parcels)(@qlik-trial\/qmfe-)/,
|
||||||
/^@qlik\/api\//,
|
|
||||||
];
|
];
|
||||||
const { external } = cfg.systemjs || {};
|
const { external } = cfg.systemjs || {};
|
||||||
return Array.isArray(external) ? external : defaultExternal;
|
return Array.isArray(external) ? external : defaultExternal;
|
||||||
|
|||||||
Reference in New Issue
Block a user