Skip to content

Commit ee15207

Browse files
authored
[turbopack] tweak the doc on the inner graph optimization (#84752)
This optimization is enabled by default and we already link to the docs so referencing the configuration option is more misleading than helpful. Fixes vercel/feedback#111264
1 parent bc51d9b commit ee15207

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

docs/01-app/03-api-reference/08-turbopack.mdx

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -134,7 +134,7 @@ This can lead to subtle rendering changes when adopting Turbopack, if applicatio
134134

135135
### Bundle Sizes
136136

137-
Turbopack does not yet have an equivalent to the [Inner Graph Optimization](https://webpack.js.org/configuration/optimization/#optimizationinnergraph) in webpack. This optimization is useful to tree shake large modules. For example:
137+
Turbopack does not yet have an equivalent to the [Inner Graph Optimization](https://webpack.js.org/configuration/optimization/#optimizationinnergraph) in webpack which is enabled by default. This optimization is useful to tree shake large modules. For example:
138138

139139
```js filename=large.module.js
140140
import heavy from 'some-heavy-dependency.js'
@@ -146,9 +146,9 @@ export function usesHeavy() {
146146
export const CONSTANT_VALUE = 3
147147
```
148148

149-
If an application only uses `CONSTANT_VALUE` Turbopack will detect this and delete the `usesHeavy` export but not the corresponding `import`. However, with the `optimization.innerGraph = true` option enabled, webpack can delete the `import` too.
149+
If an application only uses `CONSTANT_VALUE` Turbopack will detect this and delete the `usesHeavy` export but not the corresponding `import`. However, with the Inner Graph Optimization, webpack can delete the `import` too which can drop the dependency as well.
150150

151-
We are planning to offer an equivalent to the `innerGraph` optimization in Turbopack but it is still under development. If you are affected by this gap, consider manually splitting these modules.
151+
We are planning to offer an equivalent to the Inner Graph Optimization in Turbopack but it is still under development. If you are affected by this gap, consider manually splitting these modules.
152152

153153
### Build Caching
154154

0 commit comments

Comments
 (0)