Skip to content

JSDoc plugin allowing one to exempt from parsing code that may be supported by a transpiler but not JSDoc's parser.

License

Notifications You must be signed in to change notification settings

cnordhougen/jsdoc-ignore-future

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 

Repository files navigation

jsdoc-ignore-future

JSDoc plugin allowing one to exempt from parsing code that may be supported by a transpiler but not JSDoc's parser.

Install

npm install --save-dev jsdoc-ignore-future

Usage

Add "node_modules/jsdoc-ignore-future" to the plugins array in your jsdoc config. Put comments above & below code you wish for the JSDoc parser to ignore as in the following example:

//es-future>
@Decorator('foo')
//<es-future
class MyClass {
    //es-future>
    myProp = 'something';
    static myStatic = [];
    //<es-future
    
    constructor( bar ) {
        this.bar = bar;
    }
}

Configuration

You can configure what the starting and closing comments are in your jsdoc conf.json.

{
    "plugins": [ "node_modules/jsdoc-ignore-future" ],
    "ignoreFuture": {
        "start": "myStartComment",
        "end":   "myEndComment"
    }
}

About

JSDoc plugin allowing one to exempt from parsing code that may be supported by a transpiler but not JSDoc's parser.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published