You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Apr 27, 2021. It is now read-only.
/** * Gets the weekday for a given date * @param date * @param {Language} language * @param format Possible formats are "long" and "short" * @returns {string} */functiongetWeekday(date: Date,language: Language,format: Format): string{return'...';}
In TypeScript the types are already declared in the method declaration, so @param and @request don't provide any additional information, when they don't have a description (like format in the example).
There should be either all or none @param tags, so in the example they should persist, but the @returns tag should be removed. Additionally, it is possible to remove {Language} which you can do to avoid having to change it twice when you refactor.
The text was updated successfully, but these errors were encountered:
I want to request a feature.
In TypeScript you can use JSDoc:
In TypeScript the types are already declared in the method declaration, so
@param
and@request
don't provide any additional information, when they don't have a description (likeformat
in the example).There should be either all or none
@param
tags, so in the example they should persist, but the@returns
tag should be removed. Additionally, it is possible to remove{Language}
which you can do to avoid having to change it twice when you refactor.The text was updated successfully, but these errors were encountered: