I have a main CSS file style.styl
, with the container:
.container
// ...
I have another CSS file components.styl
for some React components, and these must be inside the container
.container
.componentA
// ...
.componentB
// ...
And then after built by Webpack and CSS module with the following configuration:
{
loader: require.resolve('css-loader'),
options: {
importLoaders: 1,
modules: {
localIdentName: '[name]__[local]__[contenthash:5]',
},
},
},
the .container
in style.styl
will be compiled to style__container__8cc45
the .container
in components.styl
will compiled to components__container__45aeb
Now how can I identify the container to the same name with [contenthash:5]
Thank you very much