Skip to content

Commit a74193b

Browse files
authored
Document enabling file loader old behaviour
1 parent 0d2b6ec commit a74193b

File tree

1 file changed

+12
-0
lines changed

1 file changed

+12
-0
lines changed

CHANGELOG.md

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,18 @@
2121
"media/avatar.png": "/packs/media/avatar-057862c747f0fdbeae506bdd0516cad1.png"
2222
```
2323

24+
To get old behaviour:
25+
26+
```js
27+
// config/webpack/environment.js
28+
29+
const { environment, config } = require('@rails/webpacker')
30+
const { join } = require('path')
31+
32+
const fileLoader = environment.loaders.get('file')
33+
fileLoader.use[0].options.context = join(config.source_path)
34+
```
35+
2436
### Added
2537

2638
- Namespaces for compiled packs in the public directory

0 commit comments

Comments
 (0)