Skip to content

Commit 61b77c8

Browse files
committed
Moved Webpack config, so Sails doesn't needlessly consume it.
1 parent efb3ee5 commit 61b77c8

File tree

6 files changed

+5
-5
lines changed

6 files changed

+5
-5
lines changed

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ The script `npm run build` will make Webpack build all the proper assets into th
4141
If you want to build assets, but retain spaces / tabs for debugging, you can use `npm run build:dev`.
4242

4343
#### Configuration
44-
The webpack configuration can be found in the `config/webpack` folder. The majority of the configuration can be found in [`common.config.js`](config/webpack/common.config.js). Then, the other 3 files, such as [`dev.config.js`](config/webpack/dev.config.js) extend the `common.config.js` file.
44+
The webpack configuration can be found in the `webpack` folder. The majority of the configuration can be found in [`common.config.js`](webpack/common.config.js). Then, the other 3 files, such as [`dev.config.js`](webpack/dev.config.js) extend the `common.config.js` file.
4545

4646
## Building with React
4747
React source files live in the `assets/src` folder. It is structured in such a way, where the `index.jsx` is really only used for local development (to help Webpack serve up the correct "app"). Then, there are the individual "apps", [main](assets/src/main.jsx) and [admin](assets/src/admin.jsx). These files are used as Webpack "[entry points](https://webpack.js.org/concepts/entry-points/)", to create 2 separate application bundles.

package.json

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "sails-react-bootstrap-webpack",
3-
"version": "1.0.1",
3+
"version": "1.1.0",
44
"description": "An opinionated base configuration of Sails, with Webpack for React support, and Bootstrap for styling.",
55
"keywords": [
66
"sails",
@@ -59,11 +59,11 @@
5959
"custom-tests": "echo \"(No other custom tests yet.)\" && echo",
6060
"start": "run-p open:client lift",
6161
"start:debug": "npm-run-all --parallel open:client debug",
62-
"open:client": "webpack-dev-server --mode development --open --config config/webpack/dev.config.js",
62+
"open:client": "webpack-dev-server --mode development --open --config webpack/dev.config.js",
6363
"build": "run-s clean build:prod",
6464
"build:dev": "run-s clean build:dev:webpack",
65-
"build:dev:webpack": "webpack --mode development --config config/webpack/dev-build.config.js",
66-
"build:prod": "NODE_ENV=production webpack --mode production --config config/webpack/prod.config.js",
65+
"build:dev:webpack": "webpack --mode development --config webpack/dev-build.config.js",
66+
"build:prod": "NODE_ENV=production webpack --mode production --config webpack/prod.config.js",
6767
"clean": "rimraf .tmp && mkdirp .tmp/public",
6868
"lift": "node app.js",
6969
"debug": "node --inspect app.js",
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.

0 commit comments

Comments
 (0)