react-docgen icon indicating copy to clipboard operation
react-docgen copied to clipboard

A CLI and library to extract information from React component files for documentation generation purposes.

Results 153 react-docgen issues
Sort by recently updated
recently updated
newest added

Consider the example component below which is very common. I cannot parse the props. am i doing something incorrect here? please copy paste in the playgrounds and try it for...

new feature
6.x

I have the following prop-types definition in my React component: ```typescript import PropTypes from 'prop-types'; import type { InferProps, Requireable } from 'prop-types'; const propTypes = { someFunc: PropTypes.func as...

Have some custom components wrapping 3rd party lib that has nothing to do with React. Is it possible to get `props` when a React components returns null? React component code...

With the following code: ```tsx import React from 'react'; const Checkbox = React.forwardRef((props: CheckboxProps, ref) => ); type CheckboxProps = React.InputHTMLAttributes; export default Checkbox; ``` If I process with the...

I'm using react-docgen@next on a project that uses Flow, and I'm utilizing the new `makeFsImporter` importer to be able to parse imported types. Here's my setup: ``` value = docgen.parse(source,...

The following: ``` import React from 'react'; type Props = { children: React.ReactNode; } & { children?: React.ReactNode; } const Component = ({ children }: Props) => { return {children}...

question

The ```shape``` is ```Object```, the comment of ```shape.string``` and ```shape.number``` don't work. ```js // [email protected] const code = ` import React from 'react'; import PropTypes from 'prop-types'; type Props =...

```jsx [storeui] error: Error: Cannot find module './componentDocblockHandler' Require stack: - app/node_modules/react-docgen/dist/handlers/index.js - app/node_modules/react-docgen/dist/main.js - app/packages/apps/core-commerce-reference-store/dist/cjs/server.js - app/node_modules/@oracle-cx-commerce/express-app/utils/load-app.js - app/node_modules/@oracle-cx-commerce/express-app/utils/index.js - app/node_modules/@oracle-cx-commerce/cli/actions/bundle.js - app/node_modules/@oracle-cx-commerce/cli/actions/index.js - app/node_modules/@oracle-cx-commerce/cli/cli.js ``` how to reproduce...

I recently updated `react-styleguidist` which brought `react-docgen` to `5.3.1` and I started getting a lot of warnings: ``` Warning: Cannot parse src/components/Input/Input.jsx: RangeError: Maximum call stack size exceeded It usually...

file1 `import * as React from 'react'` `export interface interface1{` `name: string` `type?: string` `}` `export class Component1 extends React.Component {}` file2 `import * as React from 'react'` `import {interface1}...