- removes the `differentialLoading` build option - differential loading is always enabled for prod builds BEFORE (without ESM): Benchmark #1: nx build demo --prod Time (mean ± σ): 13.834 s ± 1.731 s [User: 11.817 s, System: 1.352 s] Range (min … max): 11.947 s … 16.015 s 10 runs AFTER (with ESM): Benchmark #1: nx build demo --prod Time (mean ± σ): 18.711 s ± 1.310 s [User: 12.172 s, System: 1.394 s] Range (min … max): 17.232 s … 20.770 s 10 runs
30 lines
807 B
TypeScript
30 lines
807 B
TypeScript
import {
|
|
ensureProject,
|
|
uniq,
|
|
runCommand,
|
|
checkFilesExist,
|
|
forEachCli
|
|
} from './utils';
|
|
|
|
forEachCli(() => {
|
|
describe('Delegate to CLI', () => {
|
|
it('should delegate to the cli all non-standard commands', async () => {
|
|
ensureProject();
|
|
|
|
const appName = uniq('app');
|
|
runCommand(`npm run nx -- g @nrwl/web:app ${appName}`);
|
|
runCommand(`npm run nx -- build ${appName} --prod --outputHashing none`);
|
|
|
|
checkFilesExist(
|
|
`dist/apps/${appName}/index.html`,
|
|
`dist/apps/${appName}/runtime.js`,
|
|
`dist/apps/${appName}/polyfills.esm.js`,
|
|
`dist/apps/${appName}/main.esm.js`,
|
|
`dist/apps/${appName}/polyfills.es5.js`,
|
|
`dist/apps/${appName}/main.es5.js`,
|
|
`dist/apps/${appName}/styles.css`
|
|
);
|
|
}, 120000);
|
|
});
|
|
});
|