jsdoc/ts-no-unnecessary-template-expression
eslint-plugin-jsdoc
import jsdoc from "eslint-plugin-jsdoc";
export default [
{
plugins: { jsdoc },
rules: {
"jsdoc/ts-no-unnecessary-template-expression": "error",
},
},
];Catches unnecessary template expressions such as string expressions within a template literal.
/**
* @type {`A${'B'}`}
*//**
* @type {`AB`}
*/Examples from the ESLint documentation.
No tracked preset enables this rule, so it has no reach yet.
None of the tracked presets enable this rule. Turn it on with the config below.
jsdoc/ts-no-unnecessary-template-expression
eslint-plugin-jsdoc
import jsdoc from "eslint-plugin-jsdoc";
export default [
{
plugins: { jsdoc },
rules: {
"jsdoc/ts-no-unnecessary-template-expression": "error",
},
},
];Oxlint does not have this rule.
Biome does not have this rule.
Disallows (or requires descriptions for) @ts-<directive> comments, mirroring @typescript-eslint/ban-ts-comment.
Prefers function types over call signatures when there are no other properties.
Auto-escape certain characters that are input within block and tag descriptions.
Sorts tags by a specified sequence according to tag name, optionally adding line breaks between tag groups.
Requires that throw statements are documented with @throws tags.