Python
Java
PHP
IOS
Android
Nodejs
JavaScript
Html5
Windows
Ubuntu
Linux
Eslint 从另一个文件确定全局变量
我试图以这样的方式设置 ESLint 使其在对实际目标文件进行 linting 之前解析全局声明文件 这样我就不必将所有确实是全局的函数和变量声明为全局 而是让解析器弄清楚 In 一些 模块 js function do something
javascript
eslint
如何使用testing-library/no-node-access访问props.children
我已经安装成功了eslint 插件测试库 https github com testing library eslint plugin testing library并使用overrides所以它只警告我测试文件中的代码 然而 它抱怨Avo
eslint
reactprops
children
testinglibrary
./types 的大小写与底层文件系统不匹配
所以我从 eslint 收到了一些奇怪的警告 types 是流类型文件 我认为 eslint 将 checkbox 读取为小写 而实际上它是 Checkbox 大写 C I try git mv casesensitive tmp git
WEBPACK
filesystems
babeljs
eslint
如何设置 .eslintrc 来识别“require”?
我是新来的ESLint http eslint org 并且我已经成功地将 ESLint 与IntelliJ https www jetbrains com idea 开箱即用 我的 ESLint 集成无法识别node 但对文档的基本审查表
javascript
intellijidea
eslint
jshint
Lint
Svelte 与 Prettier/eslint
我正在尝试使用 svelte 制作一个应用程序来尝试一下 我想设置 prettier 和 eslint 我安装了这些依赖项和 Svelte for VS Code 的扩展 dependencies eslint 7 7 0 eslint p
VisualStudioCode
eslint
Svelte
prettier
如何处理 React JSX 中的长类名?
假设我在 React JSX 中渲染这个组件 render return h1 Some text h1 这些类触发我的 JS linter 的行太长 而且很难阅读 怎样才能分开长className将 React 组件中的属性分成多行而不破
javascript
ReactJS
eslint
JSX
VSCode 在 React 的 JSX 中错误地格式化三进制
我正在运行 VSCode 来开发我的 React 应用程序 我有一个简单的三元 isLoading
ReactJS
VisualStudioCode
JSX
eslint
禁用 create-react-app 提供的 ESLint
create react appv3 0 0 已发布 https github com facebook create react app blob master CHANGELOG md 它内部支持 TypeScript linting
ReactJS
typescript
eslint
createreactapp
ESLint 如何集成到 Create React App 中?
当我跑步时npx create react app some name 为我创建了一个简单的 React 项目 当我随后窥视package json 似乎有一些 ESLint 存在的证据 因为有 eslintConfig extends r
javascript
ReactJS
VisualStudioCode
createreactapp
eslint
如何禁用有关某些未使用参数的警告,但保留“@typescript-eslint/no-unused-vars”规则
我想在某些情况下禁用 未使用的参数 警告 但保留 未使用的变量 规则 例如 在这里我想保留参数以查看传递给解析器的内容 const Query objectType name Query definition t t field test
eslint
typescripteslint
在 eslint 上使用数组解构(prefer-destructuring)错误
这是我的代码中 eslint 不喜欢的部分 this attributes mb start date this dateInstance config defaultDate split T 0 我该如何重写它来克服这个错误 eslint
eslint
在 Vue.js 的 eslint 中删除“组件已注册但未使用”
我正在实现动态组件 其中使用
vuejs
vuejs2
eslint
如何绕过警告意外的任何。指定不同的类型 @typescript-eslint/no-explicit-any
我们有严格的零棉绒问题政策 这意味着所有错误和警告都需要修复 在我们的 React typescript 项目中面临这个 lint 错误 warning Unexpected any Specify a different type typ
typescript
eslint
Vue 3:“defineProps”引用本地声明的变量
为什么我收到警告错误消息 defineProps引用本地声明的变量 eslint vue valid define props 当我在 props 中使用自定义验证器时SFC
javascript
vuejs
eslint
vuejs3
vuesfc
如何使用 eslint 修复一条规则
我想使用 eslint 命令标志 fix只是修复一条规则 我尝试了命令 eslint fix config eslintrcsomerules js 但这不起作用 如何达到目的 My eslintrcsomerules js文件如下 mod
javascript
eslint
eslintrc
带有 --rule 选项的 ESLint CLI
我在使用 ESLint CLI 时遇到问题 rule option This is what I tried eslint rule no console error fix dry run 导致出现以下错误 选项 规则 的值无效 预期类型
commandlineinterface
eslint
Eslint:警告文件默认被忽略。使用否定忽略模式
我是 Eslint 的新手 到目前为止 我已经在本地项目中安装了 Eslint 并进行了配置 eslintrc js 文件包含 module exports env node true commonjs true es6 true moch
javascript
nodejs
eslint
如何升级Visual Studio 2019中使用的ESLint版本?
我将 ESLint 与 Visual Studio 2019 结合使用 集成效果很好 我可以直接在 IDE 中看到 ESLint 错误 但是当我向配置文件添加更多规则时 例如无异步承诺执行器 https eslint org docs ru
eslint
VisualStudio2019
如何修复 Eslint 错误“prefer-destructuring”?
我想像这样缩短 ES6 中的对象文字 const loc this props local 原因是loc foo 比打字容易得多this props local foo 但现在 ESLint 抱怨道 使用对象解构 prefer destru
javascript
ECMAScript6
eslint
预期的 catch() 或返回(promise/catch-or-return)
我是 JavaScript 新手 这是我在 javascript 中第一个在 firebase 上部署函数的函数 得到这个错误 eslint Unexpected function expression prefer arrow callb
javascript
firebase
googlecloudfunctions
eslint
1
2
3
4
5
6
...12
»