UNPKG

@lipemat/js-boilerplate

Version:

Dependencies and scripts for a no config JavaScript app

20 lines 578 B
import { getConfig } from '../helpers/config.js'; import webpack from 'webpack'; const config = await getConfig('webpack.dist.js'); const compiler = webpack(config); if (null === compiler) { throw new Error('Failed to create the webpack compiler.'); } compiler.run((err, stats) => { if (err || 'undefined' === typeof stats) { throw err; } if (stats.hasErrors()) { console.error(stats.toString(config.stats)); process.exit(1); } else { console.debug(stats.toString(config.stats)); } }); //# sourceMappingURL=dist.js.map