react-docgenHomeHomeDocsDocsPlaygroundPlayground
GitHubGitHub (opens in a new tab)
  • Getting started
    • Node.js
    • CLI
  • Extending
    • Architecture
    • Resolver
    • Handler
    • Importer
  • Reference
    • Config
    • API
    • Documentation
      • Basic
      • PropTypes
      • TypeScript
      • Flow
    • FileState
    • Handlers
      • childContextTypeHandler
      • codeTypeHandler
      • componentDocblockHandler
      • componentMethodsHandler
      • contextTypeHandler
      • defaultPropsHandler
      • displayNameHandler
      • propDocblockHandler
      • propTypeCompositionHandler
      • propTypeHandler
    • CLI
  • Release Notes
    • react-docgen
    • @react-docgen/cli
  • Home
  • Docs
    • Getting started
      • Node.js
      • CLI
    • Extending
      • Architecture
      • Resolver
      • Handler
      • Importer
    • Reference
      • Config
      • API
      • Documentation
        • Basic
        • PropTypes
        • TypeScript
        • Flow
      • FileState
        • Properties
        • Methods
      • Handlers
        • childContextTypeHandler
        • codeTypeHandler
        • componentDocblockHandler
        • componentMethodsHandler
        • contextTypeHandler
        • defaultPropsHandler
        • displayNameHandler
        • propDocblockHandler
        • propTypeCompositionHandler
        • propTypeHandler
      • CLI
    • Release Notes
      • react-docgen
      • @react-docgen/cli
    • Playground
  • Playground

On This Page

  • Properties
  • ast
  • code
  • opts
  • path
  • scope
  • Methods
  • import
  • parse
  • traverse
Question? Give us feedback → (opens in a new tab)Edit this page
Docs
Reference
FileState

FileState

Properties

ast

Type: File

code

Type: string

opts

Type: TransformOptions

path

Type: NodePath<Program>

scope

Type: Scope

Methods

import

fileState.import(path: ImportPath, name: string): NodePath | null

parse

parse(code: string, filename: string): FileState

traverse

traverse<S>(visitors: Visitor<S>, state?: S): void

FlowchildContextTypeHandler