feat: added CSS and LESS processor

This commit is contained in:
Begerad, Stefan 2021-09-09 14:18:04 -04:00
parent 48fdb643e8
commit 1a63c11b62
4 changed files with 19 additions and 1 deletions

View File

@ -1,5 +1,7 @@
import React from 'react';
import ReactDOM from 'react-dom';
import "./style/main.less";
/*
*component Welcome
*using class syntax from ES6

View File

@ -0,0 +1,3 @@
.header {
background-color: #3d3d;
}

View File

@ -0,0 +1,5 @@
@import "header.less";
@color: #f5adad;
body {
background-color: @color;
}

View File

@ -29,7 +29,15 @@ module.exports = {
//use esling-loader to hook JavaScript linter ESLint into Webpack
'eslint-loader'
]
}
},
{
test: /\.less$/,
use: [
'style-loader',
'css-loader',
'less-loader',
],
},
]
},
};