cost 191 ms
eslint 不忽略 node_modules 并在尝试 lint 时出错 - eslint not ignoring node_modules and getting error when try to lint

我正在尝试在Next.js项目中实现eslint 。文件结构如下所示 我的.eslintignore文件中有node_modules/* 。 当我尝试通过eslint --fix /sources/**/*.js对这些进行 lint 时,我遇到了错误 任何人都可以帮我解决这个问题吗? 谢谢 ...

有没有办法忽略 eslint-plugin-security 的测试文件? - Is there a way to ignore test files for eslint-plugin-security?

对于 node.js 项目,我添加了 eslint-plugin-security 并且它在我的测试/规范文件(使用 mochajs)中为代码提供了很多警告。 由于测试代码不会在生产环境中运行,这些看起来不像在项目的实际代码中那样有用。 (很多通用对象注入接收器警告) 除了将/* eslint- ...


排序:
质量:
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM