Skip to content

Commit 6af0e90

Browse files
committed
fix: Correct publicPath code snippet
1 parent 7f252ab commit 6af0e90

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/content/guides/asset-modules.mdx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ By default, under the hood, the `asset` type does `__webpack_public_path__ + imp
3131
If you set the `__webpack_public_path__` in code, the way you need to achieve it so as not to break the `asset` loading logic is to make sure you run it as the first code in your app and not use a function to do so. An example of this would be having a file called `publicPath.js` with contents
3232

3333
```javascript
34-
__webpack_public_path__ = '[https://cdn.url.com](https://cdn.url.com)';
34+
__webpack_public_path__ = 'https://cdn.url.com';
3535
```
3636

3737
And then in your `webpack.config.js` updating your `entry` field to look like

0 commit comments

Comments
 (0)