ESlint抛出错误而不是警告 [英] ESlint throw errors instead of warnings
本文介绍了ESlint抛出错误而不是警告的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
是否可以使用Eslint引发错误而不是警告?
我正在与 create-react-app
一起工作,并且希望团队中有一个非常严格的皮棉政策,并认为这可能是一个好的开始。
Is it possible to throw errors instead of warnings using Eslint?
I am working with a create-react-app
and want to have a really strict lint policy in my team, and thought that this might be a good start.
有可能吗?
推荐答案
--max-warnings
可以满足以下目的:-max-warnings = 0
表示任何警告都会导致eslint报告错误。
--max-warnings
can serve this purpose: --max-warnings=0
means that any warnings cause eslint to report an error.
https:// github .com / eslint / eslint / issues / 2309#issuecomment-219828044
这篇关于ESlint抛出错误而不是警告的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文