关于vue告警:More than 1 blank line not allowed

vscode环境开发vue-cli脚手架工程,eslint规范检查工具告警笔记

警告

警告内容

✘  http://eslint.org/docs/rules/no-multiple-empty-lines  More than 1 blank line not allowed
  src/components/question.vue:138:1

   ^

这行警告的关键信息:

More than 1 blank line not allowed 

百度翻译如下:

空行不允许超过1个

用代码来说明,即:将

    console.log('first line')
    
    console.log('second line')

修改为

    console.log('first line')
    console.log('second line')

即可。(vscode邮件自动格式化很方便)

官网指南

eslint官网关于此问题的链接:http://eslint.org/docs/rules/no-multiple-empty-lines

关于此问题,官网信息唯一值得一提的是 最大空行数可以配置 :

{ "max": 2 }
------本页内容已结束,喜欢请分享------

感谢您的来访,获取更多精彩文章请收藏本站。

© 版权声明
THE END
喜欢就支持一下吧
点赞7 分享
评论 抢沙发

请登录后发表评论

    暂无评论内容