我可以使用哪个工具生成具有默认选项的 .jshintrc 文件?

Which tool can I use to generate a .jshintrc file with default options?

我使用 JSLint 有一段时间了,最​​近发现了 JSHint。阅读 docs I learned that it can be configured using a .jshintrc file but I could not found if it's possible to generate this file using the CLI.

CLI 中是否有生成此类文件的标志(最好设置了所有选项)或允许我这样做的其他工具?

并不是真的要回答你的问题,但我在一本免费的 HTML 电子书 SpeakingJS - Style guide.

中找到了我在一些关于代码风格指南的文章中使用的 JShint

他们谈论 Google 的指南、AirBNB 的指南、jQuery 的指南等等,大多数时候这些链接提供了一个随时可用的 jshint 文件...可能这对你有帮助 :).

如果你想生成自己的JSHint,不知道你熟悉不Yeoman but this project is exactly what you re looking for : https://github.com/losingkeys/generator-jshint

生成后,任何文本编辑器都可以用来编辑这样一个简单的文件。