Uh oh!
There was an error while loading.Please reload this page.
- Notifications
You must be signed in to change notification settings - Fork698
Open
Description
Please describe what the rule should do:
The rule should warn when a custom directive is used, but not imported. The rule should also accept some kind ofignore option to avoid false positives with globally-registered custom directives.
What category should the rule belong to?
- Enforces code style (layout)
- Warns about a potential error (problem)
- Suggests an alternate way of doing something (suggestion)
- Other (please specify:)
Provide 2-3 code examples that this rule should warn about:
Should warn on:
<template> <inputv-focus></template><script setup>// vFocus is not imported or defined anywhere</script>
<template> <av-sref="someValue"><!-- anchor contents--> </a></template><script setup>// vSref is not imported or defined anywhere</script>
Should not warn on:
<template> <inputv-focus></template><script setup>importvFocusfrom'../path/to/vFocus';</script>
<template> <av-sref="someValue"><!-- anchor contents--> </a></template><script setup>importvSreffrom'../path/to/vSref';</script>
Additional context
There is a runtime warning in the browser console, but it would be cool if we can catch these issues when linting too.
[Vue warn]: Failed to resolve directive: srefMetadata
Metadata
Assignees
Labels
No labels