-
-
Notifications
You must be signed in to change notification settings - Fork 243
fix(eslint-plugin-template): prevent the slot tag from being self-closing #2088
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
fix(eslint-plugin-template): prevent the slot tag from being self-closing #2088
Conversation
…sing The slot tag is not included in the tags exposed by the aria-query library, which is used to extract native DOM elements and determine which tags can be self-closing. This fix adds the slot tag and a few other missing tags fix angular-eslint#2087
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you! May as well include all the examples to protect against regressions
packages/eslint-plugin-template/tests/rules/prefer-self-closing-tags/cases.ts
Outdated
Show resolved
Hide resolved
…-closing-tags/cases.ts
☁️ Nx Cloud ReportCI is running/has finished running commands for commit 2b8b2cb. As they complete they will appear below. Click to see the status, the terminal output, and the build insights. 📂 See all runs for this CI Pipeline Execution ✅ Successfully ran 5 targetsSent with 💌 from NxCloud. |
packages/eslint-plugin-template/tests/rules/prefer-self-closing-tags/cases.ts
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You need to please update the rule docs:
pnpm update-rule-docs
We auto generate examples from the unit tests
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #2088 +/- ##
=======================================
Coverage 90.73% 90.74%
=======================================
Files 177 177
Lines 3509 3510 +1
Branches 592 592
=======================================
+ Hits 3184 3185 +1
Misses 171 171
Partials 154 154
Flags with carried forward coverage won't be shown. Click here to find out more.
|
Thank you! |
The slot tag is not included in the tags exposed by the aria-query library, which is used to extract native DOM elements and determine which tags can be self-closing. This fix adds the slot tag and a few other missing tags
Fixes #2087