TypeScript jsdoc for interface properties

Just put the doc comment before each property:

export interface ISource {
    /**
     * Bias: bias_text[rating.bias[0]],
     */
    b: string

    /**
     * Domain: `rating.domain.replace(/^www\./, "")`
     */
    d: string
    ...
}

(Also, don’t use type annotations in JSDocs inside TS files; the compiler and tooling will ignore these types)

Leave a Comment

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)