Skip to content

Commit 0a51231

Browse files
docs(config) fix conflicts after rebasing onto master, which had moved further with rebuild branch merge (#2802)
1 parent 36198b4 commit 0a51231

File tree

1 file changed

+36
-0
lines changed

1 file changed

+36
-0
lines changed

src/content/configuration/index.mdx

Lines changed: 36 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -452,4 +452,40 @@ T> Want to rapidly generate webpack configuration file for your project requirem
452452
[Generate Custom Webpack Configuration](https://generatewebpackconfig.netlify.com/) is an interactive portal you can play around by selecting custom webpack configuration options tailored for your frontend project. It automatically generates
453453
a minimal webpack configuration based on your selection of loaders/plugins, etc.
454454

455+
Or use [webpack-cli's `init` command](https://github.com/webpack/webpack-cli/tree/master/packages/init#cli-via-webpack-cli) that will ask you a couple of questions before creating a configuration file.
456+
457+
```bash
458+
npx webpack-cli init
459+
```
460+
461+
W> You might be promted to install `@webpack-cli/init` if it is not yet installed in the project or globally.
462+
463+
T> After running `npx webpack-cli init` you might get more packages installed to your project depending on the choices you've made during configuration generation.
464+
465+
```bash
466+
npx webpack-cli init
467+
468+
ℹ INFO For more information and a detailed description of each question, have a look at https://github.com/webpack/webpack-cli/blob/master/INIT.md
469+
ℹ INFO Alternatively, run `webpack(-cli) --help` for usage info.
470+
471+
? Will your application have multiple bundles? No
472+
? Which module will be the first to enter the application? [default: ./src/index]
473+
? Which folder will your generated bundles be in? [default: dist]:
474+
? Will you be using ES2015? Yes
475+
? Will you use one of the below CSS solutions? No
476+
477+
478+
479+
480+
481+
482+
483+
484+
added 124 packages from 39 contributors, updated 4 packages and audited 25221 packages in 7.463s
485+
found 0 vulnerabilities
486+
487+
488+
Congratulations! Your new webpack configuration file has been created!
489+
```
490+
455491
[createapp.dev - create a webpack config in your browser](https://createapp.dev/webpack) is an online tool for creating custom webpack configuration. It allows you to select various features that will be combined and added to resulting configuration file. Also, it generates an example project based on provided webpack configuration that you can review in your browser and download.

0 commit comments

Comments
 (0)