Skip to content

Instantly share code, notes, and snippets.

@anfibiacreativa
Last active July 12, 2019 16:41
Show Gist options
  • Save anfibiacreativa/48e9e7a54966164ed9b3fc9f931ff06f to your computer and use it in GitHub Desktop.
Save anfibiacreativa/48e9e7a54966164ed9b3fc9f931ff06f to your computer and use it in GitHub Desktop.
// ...
"paths": {
"conf": "./config",
"tasks": "./tasks"
},
"scripts": {
"build": "npm-run-all --parallel build:*",
// you cannot write comments in package.json (or any json, so don't do this! ;)
// but to explain this, $npm_package_paths_configs refers to what you have as value in the
// paths property up there
"build:general": "webpack-cli --config \"$npm_package_paths_conf/webpack.config.js\"",
"build:js": "webpack-cli --config \"$npm_package_paths_conf/webpack.js.config.js\"",
"build:css": "webpack-cli --config \"$npm_package_paths_conf/webpack.css.onfig.js\"",
// ...
"clean": "node $NODE_DEBUG_OPTION \"$npm_package_paths_tasks/clean\"",
...
}
const jsConfig = require('./webpack.js.config');
const cssConfig = require('./webpack.css.config');
const merge = require('webpack-merge');
const generalConfig = merge([
jsConfig,
cssConfig
]);
module.exports = generalConfig;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment