W3cubDocs

/JSDoc

@member

Table of Contents

Synonyms

@var

Syntax

@member [<type>] [<name>]

Overview

The @member tag identifies any member that does not have a more specialized kind, such as "class", "function", or "constant". A member can optionally have a type as well as a name.

Examples

Using @member with Data#point
/** @class */
function Data() {
    /** @member {Object} */
    this.point = {};
}

Here is an example of using @var, a synonym of @member, to document a (virtual) variable 'foo'.

Using @var to document a virtual member
/**
 * A variable in the global namespace called 'foo'.
 * @var {number} foo
 */

The above example is equivalent to the following:

/**
 * A variable in the global namespace called 'foo'.
 * @type {number}
 */
var foo;

© 2011–2017 the contributors to the JSDoc 3 documentation project
Licensed under the Creative Commons Attribution-ShareAlike Unported License v3.0.
http://usejsdoc.org/tags-member.html