Spec-Zone.ru › JSDoc

@global

Table of Contents

  • Overview
  • Examples
  • Related Links

Overview

The @global tag specifies that a symbol should appear in the documentation as a global symbol. JSDoc ignores the symbol's actual scope within the source file. This tag is especially useful for symbols that are defined locally, then assigned to a global symbol.

Examples

Use the @global tag to specify that a symbol should be documented as global.

Document an inner variable as a global
(function() {
    /** @global */
    var foo = 'hello foo';

    this.foo = foo;
}).apply(window);

Related Links

  • @inner
  • @instance
  • @memberof
  • @static

© 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-global.html

Spec-Zone.ru

Настройки Оффлайн Что нового Помощь О нас
Spec-Zone .ru
спецификации, руководства, описания, API