Skip to content

component-name-in-template-casing did not auto fix key in JS components section #736

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
fxxkscript opened this issue Dec 21, 2018 · 0 comments

Comments

@fxxkscript
Copy link

Tell us about your environment

  • ESLint version: 5.10.0
  • eslint-plugin-vue version: 5.0.0
  • Node version: 11.5.0

Please show your full configuration:

{
  "root": true,

  "extends": [
    "plugin:vue/essential",
    "plugin:prettier/recommended",
    "eslint:recommended"
  ],

  "plugins": ["vue", "prettier"],

  "rules": {
    "prettier/prettier": ["error", { "singleQuote": true }],
    "no-unused-vars": ["error", { "args": "none" }]
  },

  "parserOptions": {
    "parser": "babel-eslint",
    "ecmaVersion": 2017,
    "sourceType": "module"
  },

  "env": {
    "browser": true,
    "node": true,
    "es6": true,
    "commonjs": true
  },

  "globals": {

  }
}

What did you do?

Now, if i use this option in single file component, it will auto fix component name in template but not in js.

<template>
<ComponentA> // this changes
</template>
<script>
var ComponentB = {
  components: {
    // this is a bug, it did not change this key
    'componentA': ComponentA
  },
}
<script>

What did you expect to happen?

<template>
<ComponentA> // this changes
</template>
<script>
var ComponentB = {
  components: {
    // this is a bug, it did not change this key
    'ComponentA': ComponentA
  },
}
<script>

What actually happened?

<template>
<ComponentA> // this changes
</template>
<script>
var ComponentB = {
  components: {
    // this is a bug, it did not change this key
    'componentA': ComponentA
  },
}
<script>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant