v3.1.0
For this release the whole plugin has been rewritten with typescript and thus is published with type declarations (don't worry, you still don't have to use typescript when using postcss-extract-media-query 😉 )
Apart from that the output.name option has been extended to allow preserving the original folder structure. Prior to this release the following wouldn't work or rather only the last processed button.css would survive because the plugin flattens the folder structure
- src
- components
- button.css
- ui
- button.css
- components
This releases solves the problem by introducing a path placeholder which allows preserving the original file path (relative from src folder)
There are two ways
- use placeholder in string:
name: '[path]/[name]-[query].[ext]' - use a name function for max control:
name: ({ path, name, query, ext }) => '...'