-
-
Notifications
You must be signed in to change notification settings - Fork 159
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-undefined-types
: false positive for template tags with defaults
#887
Comments
🎉 This issue has been resolved in version 39.3.1 🎉 The release is available on: Your semantic-release bot 📦🚀 |
I've also added a subsequent release to fix the fact that the earlier release wasn't handling defaulting template names later in a list. |
Thanks for the quick fix, @brettz9! |
crapStone
pushed a commit
to Calciumdibromid/CaBr2
that referenced
this issue
May 24, 2022
This PR contains the following updates: | Package | Type | Update | Change | |---|---|---|---| | [eslint-plugin-jsdoc](https://github.com/gajus/eslint-plugin-jsdoc) | devDependencies | patch | [`39.3.0` -> `39.3.2`](https://renovatebot.com/diffs/npm/eslint-plugin-jsdoc/39.3.0/39.3.2) | --- ### Release Notes <details> <summary>gajus/eslint-plugin-jsdoc</summary> ### [`v39.3.2`](https://github.com/gajus/eslint-plugin-jsdoc/releases/tag/v39.3.2) [Compare Source](gajus/eslint-plugin-jsdoc@v39.3.1...v39.3.2) ##### Bug Fixes - **`no-undefined-types`:** ensure parsing takes into account template names with defaults ([374daac](gajus/eslint-plugin-jsdoc@374daac)) ### [`v39.3.1`](https://github.com/gajus/eslint-plugin-jsdoc/releases/tag/v39.3.1) [Compare Source](gajus/eslint-plugin-jsdoc@v39.3.0...v39.3.1) ##### Bug Fixes - update `jsdoccomment` to support default template values; fixes [#​887](gajus/eslint-plugin-jsdoc#887) ([53e4174](gajus/eslint-plugin-jsdoc@53e4174)) </details> --- ### Configuration 📅 **Schedule**: At any time (no schedule defined). 🚦 **Automerge**: Disabled by config. Please merge this manually once you are satisfied. ♻ **Rebasing**: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox. 🔕 **Ignore**: Close this PR and you won't be reminded about this update again. --- - [ ] <!-- rebase-check -->If you want to rebase/retry this PR, click this checkbox. --- This PR has been generated by [Renovate Bot](https://github.com/renovatebot/renovate). Co-authored-by: cabr2-bot <cabr2.help@gmail.com> Reviewed-on: https://codeberg.org/Calciumdibromid/CaBr2/pulls/1370 Reviewed-by: 6543 <6543@noreply.codeberg.org> Co-authored-by: Calciumdibromid Bot <cabr2_bot@noreply.codeberg.org> Co-committed-by: Calciumdibromid Bot <cabr2_bot@noreply.codeberg.org>
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Expected behavior
No error.
Actual behavior
The type 'F' is undefined.
ESLint Config
Environment
eslint-plugin-jsdoc
version: 39.3.0Details
When a template tag is declared like
@template {Food} F
, theno-undefined-types
rule works. If the template tag has a default like@template {Food} [F=Soup]
, then theno-undefined-types
rule does not work.Support for defaults in template tags was added in TypeScript 4.5 (see microsoft/TypeScript#45483).
Previous improvements to the
no-undefined-types
rule when using template tags:no-undefined-types
: false positives inside functions for type parameters declared by template tags #559The text was updated successfully, but these errors were encountered: