-
Notifications
You must be signed in to change notification settings - Fork 1.5k
Description
I added the following type in typescript:
`
/**
- Represents an object with properties
aand an optional functionb. - @typedef {Object} Test
- @Property {string} a
- @Property {string | function} b
*/
export type Test = {
a: string
b: string | ((y: any) => string),
}
`
This is the error I am getting:
ERROR: Unable to parse a tag's type expression for source file ... with tag title "property" and text "{boolean | ((y: any) => boolean)} b": Invalid type expression "boolean | ((y: any) => boolean)": Expected "!", "$", "'", "*", ".", "...", "0", "?", "@", "Function", """, "\", "_", "break", "case", "catch", "class", "const", "continue", "debugger", "default", "delete", "do", "else", "enum", "export", "extends", "false", "finally", "for", "function", "if", "implements", "import", "in", "instanceof", "interface", "let", "new", "null", "package", "private", "protected", "public", "return", "static", "super", "switch", "this", "throw", "true", "try", "typeof", "undefined", "var", "void", "while", "with", "yield", "{", Unicode letter number, Unicode lowercase letter, Unicode modifier letter, Unicode other letter, Unicode titlecase letter, Unicode uppercase letter, or [1-9] but "(" found.