Skip to content

Commit

Permalink
docs: document newly added configurations
Browse files Browse the repository at this point in the history
  • Loading branch information
swashata committed May 26, 2021
1 parent 5c884d9 commit 77d9189
Showing 1 changed file with 19 additions and 1 deletion.
20 changes: 19 additions & 1 deletion site/docs/apis/project-configuration.md
Original file line number Diff line number Diff line change
Expand Up @@ -202,7 +202,7 @@ under `entry`, then also (if needed) chunk-splitting will be applied.
If we were to pass multiple file object, then webpack would run in [multi-compiler](https://webpack.js.org/api/node/#multicompiler)
mode, separating dependency tree from each of the file object.

Each file object has two required and three optional properties. Here's the
Each file object has two required and four optional properties. Here's the
interface.

```ts
Expand All @@ -222,6 +222,8 @@ interface FileConfig {
appDir: string,
isDev: boolean
) => webpack.Configuration);
// NEW in v6.3.0, to override project level useBabelConfig settings
useBabelConfig?: boolean;
}
```

Expand Down Expand Up @@ -406,6 +408,22 @@ We have the default config from [webpack optimization split-chunks plugin](https
with only exception of setting `chunks` to `'all'`. We can do it safely because
our PHP consumer library handles the enqueue.

## `compileNodeModules` (`object`)

Determines how `node_modules` is compiled during development and production mode.
If this is not present, then `node_modules` is compiled in both dev and prod.
However it can be configured like this.

```js
module.exports = {
// ...
compileNodeModules: {
dev: false,
prod: true,
},
};
```

## `watch` (`string`)

[Glob pattern](https://github.com/micromatch/micromatch) to watch additional
Expand Down

0 comments on commit 77d9189

Please sign in to comment.