JSDocs Typedef problem Follow
I am trying to document a type, so I start with a type defintion as below:
/**
* @typedef PluralDef
* @type {Object}
* @property {string} many the template for a plural
* @property {string} one the template for a singular
* @property {string} none the template for no value
* @property {boolean} localize does the output need to be localized
*/
WS hightlights 'PluralDef' as having a warning and when I mouse over it says:
Unresolved variable or type 'PluralDef'
How should this be specified.
Rob
FYI - I intend to the use it as follows:
/**
* The plurals support table
* @type {Object.<string, PluralDef>}
*/
var plurals = {}
Please sign in to leave a comment.
WebStorm treates 'PluralDef' as typedef type. Try changing your code as follows:
Thanks for that!
Rob