From c4db209e08fcb9d29ef15145656b3dee65d503ba Mon Sep 17 00:00:00 2001 From: Fernando Montoya Date: Wed, 7 Mar 2018 11:33:18 +0100 Subject: [PATCH] docs(concepts) Clarification about NODE_ENV and mode --- src/content/concepts/index.md | 4 ++-- src/content/concepts/mode.md | 6 ++++-- 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/src/content/concepts/index.md b/src/content/concepts/index.md index 0e700368e109..544a3a49cf4e 100644 --- a/src/content/concepts/index.md +++ b/src/content/concepts/index.md @@ -49,7 +49,7 @@ T> You can configure the `entry` property in various ways depending the needs of ## Output -The **output** property tells webpack where to emit the *bundles* it creates and how to name these files and defaults to `./dist`. You can configure this part of the process by specifying an `output` field in your configuration: +The **output** property tells webpack where to emit the *bundles* it creates and how to name these files, it defaults to `./dist`. You can configure this part of the process by specifying an `output` field in your configuration: __webpack.config.js__ @@ -159,4 +159,4 @@ module.exports = { }; ``` -[Learn more!](/concepts/mode) \ No newline at end of file +[Learn more!](/concepts/mode) diff --git a/src/content/concepts/mode.md b/src/content/concepts/mode.md index b812828a29e3..4a986fa76f72 100644 --- a/src/content/concepts/mode.md +++ b/src/content/concepts/mode.md @@ -19,8 +19,8 @@ module.exports = { }; ``` - -or pass it as a cli argument: + +or pass it as a [CLI](/api/cli/) argument: ```bash webpack --mode=production @@ -33,6 +33,8 @@ Option | Description `development` | Provides `process.env.NODE_ENV` with value `development`. Enables `NamedModulesPlugin`. `production` | Provides `process.env.NODE_ENV` with value `production`. Enables `UglifyJsPlugin`, `ModuleConcatenationPlugin` and `NoEmitOnErrorsPlugin`. +T> Please remember that setting `NODE_ENV` doesn't automatically set `mode`. + ### Mode: development