Skip to content

JSDoc @arg and @argument tags not recognized as synonyms for @param #15477

Closed
@joechung-msft

Description

@joechung-msft

TypeScript Version: 2.3

Recognize @arg and @argument as synonyms for the @param tag.

I don't know if this was by design or not, but @returns is recognized as a synonym for @return so I expected synonyms to work.

Code

// @ts-check

/**
 * @arg {string} input
 * @returns {string}
 */
export function foo(input) {
    return input.toLowerCase();
}

Expected behavior:
input is of type "string".

Actual behavior:
input is of type "any".

Metadata

Metadata

Assignees

No one assigned

    Labels

    Domain: JSDocRelates to JSDoc parsing and type generationFixedA PR has been merged for this issueSuggestionAn idea for TypeScript

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions