Skip to content

v2.10.0

Compare
Choose a tag to compare
@fkling fkling released this 25 Aug 16:18
· 2398 commits to main since this release

New

  • New findAllExportedComponentDefinitions resolver. As the name suggests, it finds all exported component definitions. This complements the resolvers for finding all component definitions and the default exported definition ( #114, @ZauberNerd )
  • New CLI option: -e, --exclude PATTERN, allows you to skip files that match the provided pattern ( #102, @wallaroo )

Fixed / improved

  • Currently resolve namespace imports to their module ( #109, @ZauberNerd )
  • Resolve MemberExpressions (such as propTypes of a stateless component) to the correct object ( #111, @ZauberNerd )
  • Handle intersection and union flow types for prop types definitions. Intersection types are supported, union types are silently ignored. Before react-docgen would throw an error. ( #118, @danez )
  • If a default prop value references an imported value, the value of the prop will now be the variable name ( #99 , @nathanmarks )
  • The jsdoc type declarations @param {x|y} and @param {*} now correctly resolve to their equivalent flow type declarations (union and mixed). ( #95 , @dickeylth )

Thanks to everyone who contributed, this is great!