Skip to content

Commit 03895b8

Browse files
committed
docs: Add options to README
1 parent ae4952d commit 03895b8

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

README.md

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -76,13 +76,14 @@ As with the CLI, this will look for the exported component created through `Reac
7676

7777
`parse` accepts more arguments with which this behavior can be customized.
7878

79-
### parse(source \[, resolver \[, handlers\]\])
79+
### parse(source \[, resolver \[, handlers \[, options\]\]\])
8080

8181
| Parameter | Type | Description |
8282
| -------------- | ------ | --------------- |
8383
| source | string | The source text |
8484
| resolver | function | A function of the form `(ast: ASTNode, recast: Object) => (NodePath|Array<NodePath>)`. Given an AST and a reference to recast, it returns an (array of) NodePath which represents the component definition. |
85-
| handlers | Array\<function\> | An array of functions of the form `(documentation: Documentation, definition: NodePath) => void`. Each function is called with a `Documentation` object and a reference to the component definition as returned by `resolver`. Handlers extract relevant information from the definition and augment `documentation`. |
85+
| handlers | Array\<function\> | An array of functions of the form `(documentation: Documentation, definition: NodePath) => void`. Each function is called with a `Documentation` object and a reference to the component definition as returned by `resolver`. Handlers extract relevant information from the definition and augment `documentation`. |
86+
| options | Pass options to react-docgen. Supported option is `legacyDecorators` which is a boolean |
8687

8788
#### resolver
8889

0 commit comments

Comments
 (0)