micromatch.matcher(path.resolve('**/*.css'))
// which is
micromatch.matcher('/path/to/my-project/packages/pkg1/**/*.css')
thus awesome.css is refused by rollup-plugin-scss and that causes rollup to throw Unexpected token
I did a small experiment (by modifying the code directly in node_modules) to change **/*.css to /**/*.css and it worked as expected.
I'm wondering can we just change the filters (['**/*.css', '**/*.sass', '**/*.scss']) to absolute ones (['/**/*.css', '/**/*.sass', '/**/*.scss']) ? Would doing so has any potential defects ?
Consider a project structure like this:
some-awesome-style-lib
is under root node_modules becauselerna --hoist
When rolling this kinda configuration, rollup would ask each plugin to transfrom
/path/to/my-project/node_modules/some-awesome-style-lib/
And the
rollup-plugin-scss
uses the following code to filter the id https://github.com/thgh/rollup-plugin-scss/blob/4456aa72dc780435874b72a6ab5fc7943e65404c/index.es.js#L6createFilter
does this under the hood:thus
awesome.css
is refused byrollup-plugin-scss
and that causes rollup to throwUnexpected token
I did a small experiment (by modifying the code directly in node_modules) to change
**/*.css
to/**/*.css
and it worked as expected.I'm wondering can we just change the filters (
['**/*.css', '**/*.sass', '**/*.scss']
) to absolute ones (['/**/*.css', '/**/*.sass', '/**/*.scss']
) ? Would doing so has any potential defects ?