documentation/test/fixture/document-exported.input.js
Tom MacWright 49347c82e7 Arv document exported (#502)
* Add a flag to document all exported bindings

This adds a boolean flag called `document-exported` (defaults to false)
that effectively adds an empty comment to all exported bindings that do
not already have a JSDoc comment. It also does the same for the
members of exported classes and objects.

```js
export class C {
  method() {}
}
```

Both `C` and `C#method` are now part of the generated documentation.

Related to #424

* Fix lint error

* Rebase and use options pragma in test file

* Create extractor type as a generalized comment/export getter

* Document exported extractor
2016-08-24 10:58:15 -04:00

36 lines
639 B
JavaScript

// Options: {"documentExported": true}
export class Class {
classMethod() {}
get classGetter() {}
set classSetter(v) {}
static staticMethod() {}
static get staticGetter() {}
static set staticSetter(v) {}
}
export var object = {
method() {},
get getter() {},
set setter(v) {},
prop: 42,
func: function() {},
};
class NotExportedClass {
classMethod() {}
get classGetter() {}
set classSetter(v) {}
static staticMethod() {}
static get staticGetter() {}
static set staticSetter(v) {}
}
var notExportedObject = {
method() {},
get getter() {},
set setter(v) {},
prop: 42,
func: function() {},
};