在搭建vue项目时候,启动后就提示

http://eslint.org/docs/rules/indent Expected indentation of 0 spaces but found 2

由于使用的webstrom每次格式化后都是缩进2个空格,习惯了。

所以改一下eslintrc.js中的规则缩进关闭了

rules: {
'indent': 'off'
} 如果规则如下设置
'indent': 'off',
'vue/script-indent': ['warn', 2, {
'baseIndent': 1
}]
正常文本缩进没问题了,但是
整行注释时又报错(如下),不知道有什么更改的解决办法了?如有大神看到,请回复下万分感谢了
methods: {
  getName () {
//    return 'aa' (报错)
    // return 'aa'(不报错)
  }
}

Expected indentation of 0 spaces but found 2的更多相关文章

  1. 解决vue/cli3.0 语法验证规则 ESLint: Expected indentation of 2 spaces but found 4. (indent)

    当你使用vue/cli3.0的时,有可能出现雁阵规则 ESLint: Expected indentation of 2 spaces but found 4. (indent) 解决方法 1.在vu ...

  2. UE初写小项目问题之命令行报错:Expected indentation of 4 spaces but found 6

    一.问题 刚开始用一个小项目练手,用vue-cli初始化项目,直接安装了所有的东西,如vue-router.ESLint.unit tests等等,当时只懂得vue-router是什么. 问题来了,在 ...

  3. VUE之命令行报错:Expected indentation of 4 spaces but found 6

    使用vue时候,经常被一大片警告惊呆了,这是webpack默认的语法检查插件ESLint在做警告, [ESLint是一个语法规则和代码风格的检查工具,可以用来保证写出语法正确.风格统一的代码] 但是我 ...

  4. QueryError:Incorrect result size: expected 1, actual 0

    1.错误描述 QueryError:Incorrect result size: expected 1, actual 0 2.错误原因 3.解决办法

  5. Celery 在Windows下启动worker时出现错误:ValueError: not enough values to unpack (expected 3, got 0)

    在公司Linux环境下没有出现问题,在回到家后直接在Windows10下运行出现错误: ValueError: not enough values to unpack (expected 3, got ...

  6. Android Studio编译错误:Unexpected lock protocol found in lock file. Expected 3, found 0.

    如果不小心手动修改了.gradle文件夹中的内容,那么再打开之前编译成功的工程时,会出现类似下面的错误: Gradle app neame project refresh failed: Unexpe ...

  7. Celery ValueError: not enough values to unpack (expected 3, got 0)的解决方案

    Celery ValueError: not enough values to unpack (expected 3, got 0)的解决方案 背景 最近因项目需要,学习任务队列Celery的用法,跟 ...

  8. ORA-00001:unique constraint violated 以及 Incorrect result size: expected 1, actual 0

    往数据库中插入数据时报错:   www.2cto.com   ORA-00001: unique constraint (IDX_CARTON_HEADER)violated.   即往CARTON_ ...

  9. win10 Celery异步任务报错: Task handler raised error: ValueError('not enough values to unpack (expected 3, got 0)

    示例代码如下: from celery import Celery app = Celery('tasks', backend='redis://×××:6379/1', broker='redis: ...

随机推荐

  1. 方法引用(Method reference)和invokedynamic指令详细分析

    方法引用(Method reference)和invokedynamic指令详细分析 invokedynamic是jvm指令集里面最复杂的一条.本文将详细分析invokedynamic指令是如何实现方 ...

  2. 移动web之一像素问题

    一.为什么会有一像素问题 弄明白这个问题,首先要知道DPR了. DPR(device pixel ratio)pixel等于picture element.设备像素比,是默认缩放100%的情况下,即D ...

  3. 2016级算法第五次上机-E.AlvinZH的学霸养成记IV

    1039 AlvinZH的学霸养成记IV 思路 难题,最大二分图匹配. 难点在于如何转化问题,n对n,一个只能攻击一个,判断是否存在一种攻击方案我方不死团灭对方.可以想到把所有随从看作点,对于可攻击的 ...

  4. js实现小球碰撞游戏

    效果图:  效果图消失只是截的gif图的问题 源码: <!DOCTYPE html> <html lang="en"> <head> <m ...

  5. [转] 基于Gitlab CI搭建持续集成环境

    [From] https://blog.csdn.net/wGL3k77y9fR1k61T1aS/article/details/78798577 前言 本文是在12月12号迅雷@赵兵在前端早读课第三 ...

  6. 织梦dedecms5.7手机站页面首页正常其他页面显示pc页面解决方法

       最近遇到的问题,用的是织梦的dedecms从以前的版本升级上来的最新版5.7sp2,客户需要手机版的,要做一个百度的验证.   这个站首页显示算是基本正常,点开里面随便一个页面会跳转到pc页面上 ...

  7. PHP输出毫秒时间戳

    代码: <?php list($msec, $sec) = explode(' ', microtime()); $msectime = (float)sprintf('%.0f', (floa ...

  8. js中报错"Maximum call stack size exceeded"解决方法

    Uncaught RangeError: Maximum call stack size exceeded 错误直译过来就是“栈溢出”,出现这个错误的原因是因为我进行了递归运算,但是忘记添加判断条件, ...

  9. [转]常用 GDB 命令中文速览

    目录 break -- 在指定的行或函数处设置断点,缩写为 b info breakpoints -- 打印未删除的所有断点,观察点和捕获点的列表,缩写为 i b disable -- 禁用断点,缩写 ...

  10. js方法的使用(z)

    http://www.108js.com/article/article1/10025.html?id=58 javascript中正则匹配有3个方法,match,exec,test.这些方法都跟字符 ...