// @allowJs: true // @checkJs: true // @target: esnext // @out: foo.js // @declaration: true // @Filename: jsdocReadonlyDeclarations.js class C { /** @readonly */ x = 6 /** @readonly */ constructor(n) { this.x = n /** * @readonly * @type {number} */ this.y = n } } new C().x function F() { /** @readonly */ this.z = 1 }