dk-webpack-parallel-simple v3.2.14
Simple lib for parallel Webpack builds
Motivation
The existing library parallel-webpack is not maintained, has huge codebase, does not support custom communication between processes, does not show low-level errors, requires separate file with configs.
This one is a light alternative based on internal Node.js child_process fork
Supports TypeScript configs
Usage
import { ChildProcess } from 'child_process';
import { run, TypeConfig } from 'dk-webpack-parallel-simple';
let childProcesses: Array<ChildProcess> = [];
const parallelConfig: TypeConfig = {
onInit(processes: Array<ChildProcess>) { childProcesses = processes; },
bailOnError: false,
configPaths: [
path.resolve(__dirname, './client.config'),
path.resolve(__dirname, './server.config'),
],
afterFirstBuild() {
childProcesses.forEach((childProcess) => {
childProcess.send('SOME_MESSAGE');
});
// ... maybe start Node.js server, browser reload service, file generation service
},
};
run(parallelConfig);
Params
bailOnError
- if true all processes will be terminated on the first error
configPaths
- array of config files' paths
afterFirstBuild
(optional) - callback that called after first compiler run on every config passed
onInit
(optional) - passes instances of forked processes so you are able to send messages to your webpack processes and get answers
28 days ago
28 days ago
28 days ago
28 days ago
28 days ago
28 days ago
1 month ago
1 month ago
1 month ago
1 month ago
1 month ago
1 month ago
1 month ago
1 month ago
3 months ago
3 months ago
3 months ago
3 months ago
3 months ago
4 months ago
10 months ago
10 months ago
10 months ago
10 months ago
9 months ago
10 months ago
9 months ago
9 months ago
7 months ago
9 months ago
7 months ago
7 months ago
10 months ago
10 months ago
10 months ago
6 months ago
6 months ago
5 months ago
6 months ago
5 months ago
7 months ago
6 months ago
6 months ago
11 months ago
11 months ago
11 months ago
11 months ago
11 months ago
11 months ago
11 months ago
11 months ago
11 months ago
11 months ago
11 months ago
11 months ago
11 months ago
11 months ago
11 months ago
11 months ago
11 months ago
11 months ago
11 months ago
11 months ago
11 months ago
11 months ago
11 months ago
11 months ago
11 months ago
11 months ago
11 months ago
2 years ago