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

Validate JSDoc argument number #55

Open
ntadej opened this issue Sep 21, 2015 · 1 comment
Open

Validate JSDoc argument number #55

ntadej opened this issue Sep 21, 2015 · 1 comment

Comments

@ntadej
Copy link

ntadej commented Sep 21, 2015

Validate if argument is required or not in JSDoc.
For example:

    /**
     * Return string based on error code
     * @param {number} id - error id
     * @param {string=} message - error message
     * @return {string} localized error string
     */
    error(id, message) { ... }

Here, error() should be marked as invalid, as id is required, whereas error(5) would be valid.

@angelozerr
Copy link
Owner

I agree that it should be cool if we have this feature which looks like #32 (comment)

I must study if tern can manage very well optional parameter to avoid having a lot of errors.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants