Topic on Manual talk:Coding conventions/JavaScript

Adding @stable as a defined tag

3
Summary by MusikAnimal
MusikAnimal (talkcontribs)

With the advent of the frontend stable interface policy, there's a need to mark things as stable. This is especially true in the near-term as most frontend code doesn't have any indication of stability, so visibly seeing @stable tells the developer that method/class is there to stay.

JSDoc/JSDuck does not currently support @stable but a similar feature has been proposed. While our generated docs won't do anything special when they see this tag, it'd be nice to be able to use it without eslint yelling.

Thus, I'm proposing we allowlist @stable through the use of the definedTags option for the check-tag-names rule.

Later, once the new frontend stable interface policy has matured, we may wish to be more granular like we do for PHP and tag things as "@stable to call", "@stable to extend", etc., but for now just being able to use "@stable" at all (without having to add an ignore rule) I think is a good start.

Samwilson (talkcontribs)

Support Sounds like a good idea to me. Sam Wilson 05:40, 18 October 2023 (UTC)

Jdlrobson (talkcontribs)

Support Jdlrobson (talk) 18:39, 20 October 2023 (UTC)