Important: This documentation covers Yarn 1 (Classic).
For Yarn 2+ docs and migration guide, see yarnpkg.com.

Package detail

esdoc-flow-type-plugin

esdoc1.7kMIT1.1.0

A flow type plugin for ESDoc [PoC]

esdoc, flow, plugin

readme

ESDoc Flow Type Plugin (PoC)

This plugin is proof of concept.

Install

npm install esdoc-flow-type-plugin

Config

{
  "source": "./src",
  "destination": "./doc",
  "plugins": [
    {"name": "esdoc-flow-type-plugin", "option": {"enable": true}}
  ]
}
  • enable is default true

Example

export class Foo {
  // without document
  member: number;

  // without document
  method1(n: number): string {
  }

  // without @param and @return
  /**
   * this is method2.
   */
  method2(n: number): string {
  }

  // without type in @param and @return
  /**
   * this is method3.
   * @param n - this is param desc.
   * @return this is return desc. 
   */
  method3(n: number): string {
  }
}

LICENSE

MIT

Author

Ryo Maruyama@h13i32maru

changelog

Changelog

1.1.0 (2018-04-30)

  • Feat
    • Much improved type reconstruction from Flow annotations (#31). Thanks @samskivert

1.0.2 (2018-04-29)

1.0.1 (2017-09-03)

  • Fix
    • [esdoc-flow-type-plugin] Broken @return {type} desc (#23) Thanks @samskivert

1.0.0 (2017-07-30)

  • Release