Component name "XXX" should always be multi-word. eslintvue/multi-word-component

68 阅读1分钟

image.png

方法一:存在.eslintrc.js文件,在文件里写入rules

rules: {
    'vue/multi-word-component-names': 'off'
  }

方法二:没有.eslintrc.js文件,在package.json文件里找到eslintConfig配置里的rules

rules: {
    "vue/multi-word-component-names": "off"
  }

注意:必须双引号,否则报错