Skip to content

Commit 2b5fc72

Browse files
committed
Merge branch '5.2' into 5.x
* 5.2: updating config for postcss-loader v4
2 parents 28ee870 + 4dc86ed commit 2b5fc72

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

frontend/encore/postcss.rst

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -43,13 +43,14 @@ You can also pass options to the `postcss-loader`_ by passing a callback:
4343
.. code-block:: diff
4444
4545
// webpack.config.js
46+
+ const path = require('path');
4647
4748
Encore
4849
// ...
4950
+ .enablePostCssLoader((options) => {
50-
+ options.config = {
51+
+ options.postcssOptions = {
5152
+ // the directory where the postcss.config.js file is stored
52-
+ path: 'path/to/config'
53+
+ config: path.resolve(__dirname, 'sub-dir', 'custom.config.js'),
5354
+ };
5455
+ })
5556
;

0 commit comments

Comments
 (0)