Skip to content

Releases: reactjs/react-docgen

v2.18.0

05 Sep 12:24
Compare
Choose a tag to compare

New

  • Add support for flow >=0.53 and the new react definitions (#209).
  • Resolve Object.keys in PropType.oneOf() (#211).
    For example:
    Component.propTypes = { foo: PropTypes.oneOf(Object.keys({ a: 1, b: 2 }))};
    // react-docgen will now correctly extract the type of foo being "a" or "b"

v3.0.0-beta6

22 Jul 00:18
Compare
Choose a tag to compare
v3.0.0-beta6 Pre-release
Pre-release

(cherry picked changes released in v2.17.0)

New

See v2.17.0.

Fixed

See v2.17.0.

Other

See v2.17.0.

  • Upgraded babylon to v7.0.0-beta17.

You can install this version via npm install react-docgen@next.

v2.17.0

22 Jul 00:06
Compare
Choose a tag to compare

New

  • Classes that define a render public class field are now considered React components. For example:

    class Component extends SomeBaseComponent {
      render = someFunction;
    }
    

    See #193 and fe55485. Thank you @birjolaxew!

  • Functions assigned to public class fields are now considered as methods. I.e. both function in the following example will be picked up by react-docgen:

    class Component extends React.Component {
      method1() {}
      method2 = () => {
    
      };
    }
    

    See 1ff84b7 and #182.

Fixed

  • Using array destructuring in class method parameters doesn't throw an error anymore. ( #197 )

Other

  • Upgraded dependencies, especially recast ( 760c426 ).

v3.0.0-beta5

15 Jun 04:24
Compare
Choose a tag to compare
v3.0.0-beta5 Pre-release
Pre-release

(cherry picked changes from v2.16.0)

New

  • -e, --exclude now accepts a regular expression to filter out files by name: -e /.*-test\.js/ The argument will only be treated as a regular expression if the parameter is only passed once ( #164).

You can install this version via npm install react-docgen@next.

v2.16.0

14 Jun 23:01
Compare
Choose a tag to compare

New

  • -e, --exclude now accepts a regular expression to filter out files by name: -e /.*-test\.js/ The argument will only be treated as a regular expression if the parameter is only passed once ( #164).

Thank you @wallaroo for your contribution!

v3.0.0-beta4

03 May 15:22
Compare
Choose a tag to compare
v3.0.0-beta4 Pre-release
Pre-release

New

  • @wcjordan added support for the create-react-class module! ( #179 ) (cherry picked) from v2.15.0

You can install this version via npm install react-docgen@next.

v2.15.0

03 May 15:21
Compare
Choose a tag to compare

New

  • @wcjordan added support for the create-react-class module! ( #179 )

v2.14.1

18 Apr 23:40
Compare
Choose a tag to compare

Fixed

v3.0.0-beta3

13 Apr 03:54
Compare
Choose a tag to compare
v3.0.0-beta3 Pre-release
Pre-release
  • Upgraded to babylon v7.0.0-beta.8
  • Cherry-picked some changes released with v2.14.0

You can install this version via npm install react-docgen@next.

v2.14.0

13 Apr 03:48
Compare
Choose a tag to compare

New

Improvement

  • Ignore coverage/ folder when publishing to npm, reducing package size by more than 50%! ( #166, @fabiosantoscode )