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

[no-undef-components] false positive for "setup" components #1975

Closed
2 tasks done
Ky6uk opened this issue Sep 16, 2022 · 2 comments · Fixed by #1976
Closed
2 tasks done

[no-undef-components] false positive for "setup" components #1975

Ky6uk opened this issue Sep 16, 2022 · 2 comments · Fixed by #1976

Comments

@Ky6uk
Copy link

Ky6uk commented Sep 16, 2022

Checklist

  • I have tried restarting my IDE and the issue persists.
  • I have read the FAQ and my problem is not listed.

Tell us about your environment

  • ESLint version: 8.23.1
  • eslint-plugin-vue version: 9.5.0
  • Node version: 18.4.0
  • Operating System: Mac OS

Please show your full configuration:

{
    "parserOptions": {
        "parser": "@typescript-eslint/parser",
        "extraFileExtensions": [".vue"]
    },

    "extends": ["plugin:vue/base"],

    "rules": {
        "vue/no-undef-components": "error"
    }
}

What did you do?

<template>
  <AppHeader />
</template>

<script setup lang="ts">
  import AppHeader from '@/components/AppHeader.vue';
</script>

What did you expect to happen?

No error produced.

What actually happened?

/private/tmp/eslint-vue-no-undef-components-bug/App.vue
  2:3  error  The '<AppHeader>' component has been used, but 'AppHeader' only refers to a type  vue/no-undef-components

✖ 1 problem (1 error, 0 warnings)

Repository to reproduce this issue

https://github.com/Ky6uk/eslint-vue-no-undef-components-bug

@FloEdelmann
Copy link
Member

CC @Amorites, follow-up to #1967

@ota-meshi
Copy link
Member

I will fix it.

Ky6uk pushed a commit to GreenPie/eslint-config-greenpie that referenced this issue Sep 19, 2022
Fixed [`vue/no-undef-components`](vuejs/eslint-plugin-vue#1975)
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 a pull request may close this issue.

3 participants