当前位置: 首页 > news >正文

在哪个网站上找超市做生鲜百度推广代理怎么加盟

在哪个网站上找超市做生鲜,百度推广代理怎么加盟,河北建设厅官方网站,现在.net做网站的多吗case: 最近使用webpack打包js资源中使用到了VS Code中的eslint插件辅助eslint plugin对代码进行校验,在.eslintrc.js文件中以及webpack.config.js配置好后, 在控制台运行npx webpack可以读取到eslint plugin的检测结果 一、eslint插件读取项目中.eslint…

case: 最近使用webpack打包js资源中使用到了VS Code中的eslint插件辅助eslint plugin对代码进行校验,在.eslintrc.js文件中以及webpack.config.js配置好后,
在控制台运行npx webpack可以读取到eslint plugin的检测结果

一、eslint插件读取项目中.eslintrc.js配置文件

1、 eslint插件却始终不生效,在代码里没有eslint插件该有的红色波浪线
在这里插入图片描述
查阅eslint插件官网,找到如下描述:

eslint.enable: enable/disable ESLint for the workspace folder. Is enabled by default.
  1. 如图,查找配置项找到configFile,若有,则看配置读取文件是否正确,若不正确,直接删掉吧,

configFile如果不设置,ESLint 会在当前工作目录及其父目录中查找默认的配置文件

在这里插入图片描述

  1. 所以在vscode配置文件中设置eslint.enable: true,或者直接在配置setting.json文件中删除此配置,(因为有提示.enable配置将被弃用
二、 eslint插件读取.eslintignore文件失效(eslintignore文件不生效)
  1. 继续查阅文档
eslint.workingDirectories - specifies how the working directories ESLint is using are computed. ESLint resolves configuration files (e.g. eslintrc, .eslintignore) relative to a working directory so it is important to configure this correctly. If executing ESLint in the terminal requires you to change the working directory in the terminal into a sub folder then it is usually necessary to tweak this setting. (see also ESLint class options#cwd). Please also keep in mind that the .eslintrc* file is resolved considering the parent directories whereas the .eslintignore file is only honored in the current working directory. The following values can be used:[{ "mode": "location" }] (@since 2.0.0): instructs ESLint to uses the workspace folder location or the file location (if no workspace folder is open) as the working directory. This is the default and is the same strategy as used in older versions of the ESLint extension (1.9.x versions).
[{ "mode": "auto" }] (@since 2.0.0): instructs ESLint to infer a working directory based on the location of package.json, .eslintignore and .eslintrc* files. This might work in many cases but can lead to unexpected results as well.
string[]: an array of working directories to use. Consider the following directory layout:
root/client/.eslintrc.jsonclient.jsserver/.eslintignore.eslintrc.jsonserver.js
Then using the setting:"eslint.workingDirectories": [ "./client", "./server" ]
will validate files inside the server directory with the server directory as the current eslint working directory. Same for files in the client directory. The ESLint extension will also change the process's working directory to the provided directories. If this is not wanted a literal with the !cwd property can be used (e.g. { "directory": "./client", "!cwd": true }). This will use the client directory as the ESLint working directory but will not change the process`s working directory.
[{ "pattern": glob pattern }] (@since 2.0.0): Allows to specify a pattern to detect the working directory. This is basically a short cut for listing every directory. If you have a mono repository with all your projects being below a packages folder you can use { "pattern": "./packages/*/" } to make all these folders working directories.

翻译一下

eslint.workingDirectories 此配置其实就是设置eslint工作目录,所以我们在setting.json文件中配置工目录

[{ "mode": "location" }] 默认的
[{ "mode": "auto" }] 指示ESLint根据包的位置推断工作目录。.eslintignore和.eslintrc*文件。这可能在许多情况下有效,但也可能导致意想不到的结果
[{ "pattern": glob pattern }]允许指定检测工作目录的模式。这基本上是列出每个目录的捷径。如果你有一个单一的存储库,所有的项目都在一个包文件夹下,你可以使用{"pattern": "./packages/*/"}将所有这些文件夹设置为工作目录。

很显然。默认的配置噶了,所以剩下下面两个推断指定
在这里插入图片描述

http://www.dinnco.com/news/87325.html

相关文章:

  • 哪有培训网站开发app运营
  • 什么网站可以做十万的分期付款百度app官方下载
  • 网站建设同行友情链接中文搜索引擎有哪些平台
  • 四川省住房和城乡建设厅官网下载seo快速优化方法
  • 玉林网站推广网络优化seo薪酬
  • 网站想自己做怎么弄seo网站内容优化有哪些
  • 政府网站建设技术服务济南网站建设
  • 河南洛阳疫情通报厦门seo俱乐部
  • 做gay网站违法吗网络域名
  • 政府信息网站建设论文搜索引擎竞价推广的优势
  • 注册一个空壳建筑公司郑州优化网站关键词
  • 网站系统分析的步骤有哪些沧州seo公司
  • 深圳网络优化seoaso优化教程
  • 做婚庆的网站有哪些内容培训心得体会范文大全1000字
  • 橙色可以做哪些网站天津关键词优化网站
  • 网站制作的收费电商平台推广费用大概要多少
  • 南阳做网站收费做网络推广的公司
  • seo优化轻松seo优化排名重庆seo网站哪家好
  • 植物园门户网站建设方案百度搜索引擎技巧
  • 怎么给自己的网站做排名长尾关键词举例
  • 心理健康网站建设论文百度推广搜索排名
  • 建网站的好处it行业培训机构一般多少钱
  • 宣城seo百度爱采购优化排名软件
  • 黄山旅游最佳路线优化seo
  • 为把网站建设更好宁波优化关键词首页排名
  • 网站引导动画怎么做的湖南网络推广机构
  • erp系统的优点百度提升优化
  • 简单wordpress360优化大师app下载
  • 上海800做网站seo技术推广
  • 免费的crm软件系统北京网站优化服务