You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: src/content/migrate/5.mdx
+22Lines changed: 22 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -126,6 +126,28 @@ If you were not able to upgrade some plugins/loaders to the latest in Upgrade we
126
126
}
127
127
```
128
128
129
+
- If you have output.library or output.libraryTarget defined, change the property names: (output.libraryTarget -> output.library.type, output.library -> output.library.name). Example
130
+
131
+
```json
132
+
// for webpack 4
133
+
{
134
+
output: {
135
+
library: 'MyLibrary',
136
+
libraryTarget: 'commonjs2'
137
+
}
138
+
}
139
+
140
+
// for webpack 5
141
+
{
142
+
output: {
143
+
library: {
144
+
name: 'MyLibrary',
145
+
type: 'commonjs2'
146
+
}
147
+
}
148
+
}
149
+
```
150
+
129
151
If you were using WebAssembly via import, you should follow this two step process:
130
152
131
153
- Enable the deprecated spec by setting `experiments.syncWebAssembly: true`, to get the same behavior as in webpack 4.
0 commit comments