@this
Оглавление
Синтаксис
@this <namePath>
Обзор
Тег @this указывает, к чему относится ключевое слово this при использовании внутри другого символа.
Примеры
В приведенном ниже примере тег @this приводит к документированию "this.name" как "Greeter#name" вместо глобального символа с именем "name".
/** @constructor */
function Greeter(name) {
setName.apply(this, name);
}
/** @this Greeter */
function setName(name) {
/** document me */
this.name = name;
}
Связанные ссылки
© 2011–2017 the contributors to the JSDoc 3 documentation project
Licensed under the Creative Commons Attribution-ShareAlike Unported License v3.0.
https://jsdoc.app/tags-this.html