当前位置:网站首页>. eslintrc. JS configuration
. eslintrc. JS configuration
2022-06-26 07:56:00 【Forge ahead and have a bright future】
/**
* Configuration files can have a hierarchical structure Inheritable
* To code, you need to first convert the source code into an abstract syntax tree ( There will be a space in the following AST and babel)
*/
module.exports = {
root:true,// Root profile
extends:'airbnb', // Enable extends Inherit , Inherited from airbnb, You need to put it up root Comment out
parser:'babel-eslint',
parserOptions:{
sourceType:'module',
ecmaVersion:2015
},
env:{
browser:true, // window.a
node:true
},
// Enabled code checking rules and respective error levels
// Check the code first , If it is found to be incorrect , Will try to fix , If the repair is successful , Carry on
rules:{
"indent":["erroe",2],// Indent style , Close as false
"quotes":"off",// Type of quotation marks
"no-console":"off" // No use console.log
}
}aribnb It's a collection of rules , In the end are all eslint use
1、 We can still do that VScode install eslint Use with plug-ins , Configure automatic repair


vscode Can be generated automatically settings.js file
Configure automatic repair
2、 On the newline character problem solving

open webpack Of eslint To configure , Turn off line breaks

3、webpack read eslint package ,eslint Package read configuration file
边栏推荐
- JS Date object
- Pic 10B parsing
- Listview control
- Cloud native integration data warehouse heavy release
- buuresevewp
- 2022 ranking of bank financial products
- Flutter (III) - master the usage of dart language in an article
- Web technology sharing | webrtc recording video stream
- MFC writes a suggested text editor
- B站增量数据湖探索与实践
猜你喜欢

Chapter VII (structure)

What are the characteristics of digital factory in construction industry

Nine hours, nine people and nine doors (01 backpack deformation) - Niuke

数据中心灾难恢复的重要参考指标:RTO和RPO

4 best practices for wireless (OTA) updates

Apache InLong毕业成为顶级项目,具备百万亿级数据流处理能力!

WiFi-802.11 2.4G频段 5G频段 信道频率分配表

Web technology sharing | webrtc recording video stream

Important reference indicators for data center disaster recovery: RTO and RPO

What is Wi Fi 6 (802.11ax)? Why is Wi Fi 6 important?
随机推荐
我想造SQL数据(存储结构)
Median segmentation (find rules) - Niuke
Data governance: from top project to data culture!
Use middleware to record slow laravel requests
OSPF design principles, commands take H3C as an example
Technology sharing | mysql:caching_ sha2_ Password quick Q & A
I want to open a stock account at a discount. How do I do it? Is it safe to open a mobile account?
Webrtc has become the official standard of W3C and IETF, and mobile terminal development
Google Earth engine (GEE) 01- the prompt shortcut ctrl+space cannot be used
Open a file at line with'filename:line'syntax - open a file at line with'filename:line' syntax
I want to create SQL data (storage structure)
Getdrawingcache of view is empty. Solution: interview questions for Android audio and video development
Exploration and practice of incremental data Lake in station B
Yyds dry inventory kubernetes easy service discovery and load balancing (11)
The long path of Xiao Sha (graph theory, Euler diagram)
Baoyan postgraduate entrance examination interview - Network
Two models of OSPF planning: double tower Raider and dog tooth crisscross
Multi interface switching in one UI of QT
4 best practices for wireless (OTA) updates
Orderly arrangement