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 parsing error in type expressions for @param tags #491

Open
stockerman7 opened this issue Apr 8, 2023 · 0 comments
Open

JSDoc parsing error in type expressions for @param tags #491

stockerman7 opened this issue Apr 8, 2023 · 0 comments

Comments

@stockerman7
Copy link

Hello! I encountered a problem with the type expressions of JSDoc @param tags in the CSInterface.js file(CEP 10.x Used). The issue occurs in lines 1221 and 1262. When running JSDoc, it throws the following errors:

ERROR: Unable to parse a tag's type expression for source file /Users/[user_name]/Desktop/Adobe Photoshop Dev/Adobe Photoshop HTML Panels Development/CSInterface.js in line 1221 with tag title "param" and text "keyEventsInterest      A JSON string describing those key events you are interested in. A null object or
metaKey:  [optional] (Mac Only) a Boolean that indicates if the Meta key was pressed (true) or not (false) when the event occu                     On Macintosh keyboards, this is the command key. To detect Windows key on Windows, please use keyCode ins]": Invalid type expression ""keyCode": 48": Expected "!", ".", "<", "=", "?", "[]", "|", or end of input but ":" found.
ERROR: Unable to parse a tag's type expression for source file /Users/[user_name]/Desktop/Adobe Photoshop Dev/Adobe Photoshop HTML Panels Development/CSInterface.js in line 1262 with tag title "param" and text "keyEventsInterest      A JSON string describing those key events you are interested in. A null object or
metaKey:  [optional] (Mac Only) a Boolean that indicates if the Meta key was pressed (true) or not (false) when the event occu                     On Macintosh keyboards, this is the command key. To detect Windows key on Windows, please use keyCode ins]": Invalid type expression ""keyCode": 48": Expected "!", ".", "<", "=", "?", "[]", "|", or end of input but ":" found.

It seems that the type expressions in the mentioned lines are not following the correct JSDoc syntax. Please take a look at this issue and update the type expressions accordingly to prevent parsing errors when generating documentation.

I found a solution by updating the type expressions in the JSDoc comments to follow the correct syntax. Here's the updated JSDoc comment for the problematic lines:

/**
 * ...
 * @param {string} keyEventsInterest - A JSON string describing those key events you are interested in. A null object or...
 * @param {boolean} [metaKey] - (Mac Only) A Boolean that indicates if the Meta key was pressed (true) or not (false) when the event occurred. On Macintosh keyboards, this is the command key. To detect Windows key on Windows, please use keyCode instead.
 * ...
 */

Please consider updating the JSDoc comments in the CSInterface.js file with the suggested fix to prevent parsing errors when generating documentation.

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

1 participant