-
-
Notifications
You must be signed in to change notification settings - Fork 832
Labels
A-linterArea - LinterArea - Linter
Description
Enabled jsdoc plugin and all rules.
What happened?
Oxlint's jsdoc/check-tag-names rule incorrectly identifies an email address (containing an @ symbol) as a JSDoc tag when it appears within the description of another tag (like @license). This also happends when you write npm packages like @vue/shared in js doc
Reproduced Code
/**
* @license bcrypt.js (c) 2013 Daniel Wirtz <[email protected]>
* Released under the Apache License, Version 2.0
*/Current Behavior
Oxlint reports an error:
× eslint-plugin-jsdoc(check-tag-names): Invalid tag name found.
help: @dcode.io> is invalid tag name.
Expected Behavior
The @dcode.io should be treated as plain text. According to the official JSDoc documentation (Block and Inline Tags):
- Block Tags: "Block tags always begin with an at sign (@). Each block tag must be followed by a line break, with the exception of the last block tag..."
- Inline Tags: "inline tags and their text must be enclosed in curly braces ({ and })."
In the example provided:
@dcode.iois not followed by a line break to act as a Block Tag, nor is it at the start of a new tag section.@dcode.iois not enclosed in{}to be an Inline Tag.
Therefore, any @ symbol appearing in the middle of a description that is not wrapped in curly braces should be ignored by the check-tag-names rule.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
A-linterArea - LinterArea - Linter