Skip to content
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

JSdoc description of function should include a few examples of result #268

Open
czlowiek488 opened this issue May 20, 2022 · 1 comment
Open
Labels
enhancement New feature or request PR is welcome

Comments

@czlowiek488
Copy link

czlowiek488 commented May 20, 2022

Description

JSdoc should include result examples for each example.
This would make finding correct method easier.

It could be fancy to fill examples automatically on some npm hook.
If we agree to solution I may implement it.

Proposed solution

/**
 * Generate a random credit card brand.
 *
 * @category Finance
 *
 * @example
 *
 * randCreditCardBrand()
 * 
 * "Visa"
 * "Visa Electron"
 * "UATP"
 */

image

Alternatives considered

No response

Do you want to create a pull request?

Yes

@NetanelBasal
Copy link
Member

You're welcome to submit a PR. You can start with POC that shows one example.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request PR is welcome
Projects
None yet
Development

No branches or pull requests

2 participants