Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- webpack(config, (err, stats) => {
- if (err) {
- console.error(err.stack || err);
- if (err.details) {
- console.error(err.details);
- }
- return;
- }
- const info = stats.toJson();
- if (stats.hasWarnings() || stats.hasErrors()) {
- const messages = [...info.warnings, ...info.errors];
- messages.forEach(message => console.log(chalk.red(message)));
- } else {
- console.log(chalk.green("\nš All good. Bundles are a-ok!"));
- console.log(
- chalk.green("-----------------------------------------------------")
- );
- console.log(
- stats.toString({
- colors: true,
- modules: false,
- entrypoints: false
- })
- );
- console.log(
- chalk.green("-----------------------------------------------------")
- );
- }
- });
Add Comment
Please, Sign In to add comment