refactor: assume dev
This commit is contained in:
parent
126d86ef61
commit
f1ed06b2fb
|
@ -21,7 +21,6 @@ module.exports = async (flecks) => {
|
||||||
({config, options}) => {
|
({config, options}) => {
|
||||||
const dll = flecks.get('@flecks/http/server.dll');
|
const dll = flecks.get('@flecks/http/server.dll');
|
||||||
if (dll.length > 0) {
|
if (dll.length > 0) {
|
||||||
const isProduction = 'production' === config.get('mode');
|
|
||||||
// Build the library and manifest.
|
// Build the library and manifest.
|
||||||
config.context(options.root);
|
config.context(options.root);
|
||||||
const entries = config.entry('index').clear();
|
const entries = config.entry('index').clear();
|
||||||
|
@ -42,14 +41,13 @@ module.exports = async (flecks) => {
|
||||||
);
|
);
|
||||||
// Output.
|
// Output.
|
||||||
config
|
config
|
||||||
.devtool(isProduction ? 'source-map' : 'cheap-module-source-map');
|
.devtool('cheap-module-source-map');
|
||||||
config.output
|
config.output
|
||||||
.path(options.output)
|
.path(options.output)
|
||||||
.library('flecks_http_vendor')
|
.library('flecks_http_vendor')
|
||||||
.filename('http-vendor.js');
|
.filename('http-vendor.js');
|
||||||
config.node
|
config.node
|
||||||
.set('fs', 'empty');
|
.set('fs', 'empty');
|
||||||
|
|
||||||
// Resolution.
|
// Resolution.
|
||||||
config.resolve.extensions
|
config.resolve.extensions
|
||||||
.merge([
|
.merge([
|
||||||
|
|
Loading…
Reference in New Issue
Block a user