Closed
Description
Hi there, looking forward to getting this loader in action!
I'm hitting a strange error with a pretty basic setup, and I dug through the issues but couldn't find anything relevant. Apologies if this has been addressed.
I'm seeing this error:
Module build failed: Error:
Something wrong with provided resources.
Make sure 'options.resources' is String or Array of Strings.
Here's my snippet from module.rules
in my webpack config:
module: {
rules: [
{
test: /\.js$/,
loader: 'babel-loader',
query: {
presets: ['react', ['es2015', { modules: false }], 'stage-0'],
plugins: ['react-hot-loader/babel']
},
include: path.join(__dirname, 'src')
},
{
test: /\.scss$/,
use: [
{
loader: 'style-loader', options: {
sourceMap: true
}
},
{
loader: 'css-loader',
options: {
localIdentName: '[hash:base64:4]',
importLoaders: 1,
sourceMap: true,
modules: true
}
},
{
loader: 'postcss-loader', options: {
sourceMap: true
}
},
{
loader: 'sass-loader',
options: {
sourceMap: true,
includePaths: [
path.join(__dirname, 'src')
]
}
},
{
loader: 'sass-resources-loader',
options: {
resources: './src/modules/shared/resources.scss'
}
}
]
}
]
},
I've tried using path.join
to define my path as well. Any idea what I might be missing? Thanks in advance.