Component name “regist” should always be multi-word.eslint solution in Vue file naming

This is an error caused by eslint verification:

The solution for Vue2

Enter the .eslintrc.js file and set:

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

module.exports = {
  ……
  overrides: [
    {
      files: ['src/views/**/*.vue'],
      rules: {
        'vue/multi-word-component-names': 0,
      },
    },
  ]
}

Vue3's solution is similar

Configure the .eslintrc.cjs file:

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

The third way > turn off the verification of eslint, very rude

Also find eslintrc.jsthe file and add the following code to its configuration:

// 关闭eslint校验
lintOnSave: false 

 After configuration, there is no error message:

Guess you like

Origin blog.csdn.net/weixin_44786530/article/details/130948393