-
Notifications
You must be signed in to change notification settings - Fork 67
Open
Description
Problem
The mfb.scss file included in the npm distribution references _/_slidein.scss which is not included.
That makes mfb.scss almost unusable. That is
@import '~react-mfb/mfb.scss';
causes
ERROR in ./node_modules/css-loader!./node_modules/sass-loader/lib/loader.js?{}!./src/app/mfb.scss
Module build failed:
@import "_/_slidein";
^
File to import not found or unreadable: _/_slidein.
Solution
Include mfb/src/_ folder in the npm distribution.
Workaround
When using webpack with sass-loader
- Include a copy of mfb/src/_ in your project's sources, e.g in
src/_folder - In
webpack.config.jsinclude:
module: {
rules: [
/*...*/
{
test: /\.scss$/,
use: [
'style-loader',
'css-loader',
{
loader: 'sass-loader',
options: {
/* or other directory where you've placed the copy of _*/
includePaths: ["src"]
}
}
]
}
]
},
lzwsoar
Metadata
Metadata
Assignees
Labels
No labels