Skip to content
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

Ignore well known tags in component-name-in-template-casing #2031

Merged
merged 2 commits into from Nov 23, 2022
Merged

Ignore well known tags in component-name-in-template-casing #2031

merged 2 commits into from Nov 23, 2022

Conversation

Kaciras
Copy link
Contributor

@Kaciras Kaciras commented Nov 6, 2022

Vue does not treat built-in HTML tags as components, so them should be always excluded from verification.

e.g.

<template>
    <div/>
<template>
<script setup>
    import Div from "component"
</script>

will be compiled to

import Div from "component"

const __sfc__ = {
  __name: 'App',
  setup(__props) {

return (_ctx, _cache) => {
  // `Div` is not used.
  return (_openBlock(), _createElementBlock("div"))
}
}

Copy link
Member

@ota-meshi ota-meshi left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

@FloEdelmann FloEdelmann changed the title Fix false positives for well known tags in component-name-in-template-casing Ignore well known tags in component-name-in-template-casing Nov 23, 2022
@FloEdelmann FloEdelmann merged commit 2d46741 into vuejs:master Nov 23, 2022
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

Successfully merging this pull request may close these issues.

None yet

3 participants