Fix css conflicts on diff syntaxhighlighting by using a css module

This commit is contained in:
Sebastian Sdorra
2020-10-23 13:06:36 +02:00
parent ea1eab6356
commit 5f30cf8f30
10 changed files with 156 additions and 113 deletions

View File

@@ -90,8 +90,16 @@ module.exports = [
use: [
// Creates `style` nodes from JS strings
"style-loader",
// Translates CSS into CommonJS
"css-loader",
{
loader: "css-loader",
options: {
// Run `postcss-loader` on each CSS `@import`, do not forget that `sass-loader` compile non CSS `@import`'s into a single file
// If you need run `sass-loader` and `postcss-loader` on each CSS `@import` please set it to `2`
importLoaders: 1,
// Automatically enable css modules for files satisfying `/\.module\.\w+$/i` RegExp.
modules: { auto: true }
}
},
// Compiles Sass to CSS
"sass-loader"
]