current position:Home>Use less and CSS modules in react scaffold Engineering
Use less and CSS modules in react scaffold Engineering
2022-06-24 07:53:02【Zhangxiaolang】
First exposure webpack Related configuration Execute the following code
npm run eject
download less And less-loader I used yarn You download it according to your situation
yarn add less less-loader
Enter the root directory config Medium webpack.config.js In profile stay sass-loader Add the following code after
Probably 493 Row or so
// Less Parsing configuration
{
test: lessRegex,
exclude: lessModuleRegex,
use: getStyleLoaders(
{
importLoaders: 2,
sourceMap: isEnvProduction && shouldUseSourceMap,
modules: true,// Turn on
},
'less-loader'
),
sideEffects: true,
},
{
test: lessModuleRegex,
use: getStyleLoaders(
{
importLoaders: 2,
sourceMap: isEnvProduction && shouldUseSourceMap,
modules: true,
getLocalIdent: getCSSModuleLocalIdent,
},
'less-loader'
)
},
among modules:true That is to say Turn on CSS Modules The place of
copyright notice
author[Zhangxiaolang],Please bring the original link to reprint, thank you.
https://en.qdmana.com/2022/175/202206240328340971.html
The sidebar is recommended
- JavaScript raw values and wrapper objects
- Application of Python simplehttpserver
- The problem of UMI & react packaging and deploying to non root directory and refreshing Error 404 is solved
- Is bootstrap or Vue the first choice for self-study
- Bootstrap react or bootstrap Vue
- One article can understand the detailed explanation of nginx operation. Are you still checking for omissions and filling vacancies!
- How to utilize the old front-end devices to the cloud through easycvr intelligent edge gateway devices to create AI course intelligent applications
- Introduction to web front end to actual combat: absolute path, relative path and root directory of HTML import file
- HTML basics form
- Shadow element CSS3 box shadow attribute
guess what you like
AngularJS Bootstrap
Angularjs contains
Angularjs animation
The nginx server sets the picture anti-theft chain to prohibit the picture from being linked outside
This is a cost-effective SUV. It costs less than 50 cents a kilometer, has a wheelbase of nearly 2.8 meters, and sells for only 79900 yuan_ Europe_ Plus_ Design
About nginx
How does endless restart the Go program without stopping?
http net::ERR_ HTTP2_ PROTOCOL_ Error error finding
On BOM and DOM (7): HTML DOM event object attributes and DOM event detailed list
Analysis and practice of HTML5 mouse drag sorting and resize implementation scheme
Random recommended
- On BOM and DOM (3): DOM node operation - element style modification and DOM content addition, deletion, modification and query
- Embrace cloud native, Tencent releases TCSs container security service!
- Is there any way for FC in react+ts to set the component of function keyword
- How to write the V-model of vue2/3 custom components?
- Error using vuescoll!
- When HTML accesses the parent directory, the file content cannot be displayed normally in the browser after reading
- How to embed tabelau in the front page of react
- Vue component communication data does not update rendering
- It is very convenient to use ECs to build a drawing bed and hexo one click deployment
- How does webstorm set the bootstrap auto prompt
- Nginx cross domain understanding, simulation and solution
- Front page exercise
- How to hide the value in El form item in Vue and set the value of input box to be read-only
- Springboot+vue to realize campus second-hand Mall (graduation design I)
- Node. JS installation
- Summary of 2022 blue team HW elementary interview questions
- Screenshot of angular page (scroll bar displays completely)
- JavaScript object field splicing
- How to repair garbled code in HTML
- Display CSV as a table in JavaScript (simple example)
- How to read files using JavaScript
- Example of JavaScript FileReader API processing files
- Springboot+vue project tourism information recommendation system [source code open source]
- Ultra wideband pulse positioning scheme, UWB precise positioning technology, wireless indoor positioning application
- Elementui used tabs to step on the pit
- Ant Design Vue - remove the input component border and the border blue shadow effect when getting focus
- Get httponly protected cookies across sub domains through XSS
- Coding specification - Vue project
- Code writing specification - Javascript
- Code specification - HTML
- Code writing specification - CSS
- CSS Notes 6
- Quickly set up PgSQL for serverless
- 404405 troubleshooting after Vue uses proxy packaging
- Vue3 TS learning
- What is the charm of python, which is warmly pursued by countless programmers?
- HTML Basics
- CSS Foundation
- CSS (PC side) three methods of traditional page layout
- Inline element, block element, inline block element