← All recipes
Moderne licensed

Find React prop usage

Recipe IDorg.openrewrite.react.search.find-prop-usageArtifact@openrewrite/recipes-react

Finds all prop usages on React JSX elements, with optional filtering by component and prop name.

Single recipeProprietary

Usage

This recipe has no required configuration options. You’ll need the Moderne CLI configured before running the command below.

mod run . --recipe org.openrewrite.react.search.find-prop-usage

If the recipe isn’t available locally, install it with:

mod config recipes npm install @openrewrite/recipes-react

Options

NameTypeDescription
componentNameOptional component name to filter (e.g., 'Button'). If not specified, finds props on all components.
e.g. Button
propNameOptional prop name to filter (e.g., 'onClick'). If not specified, finds all props.
e.g. onClick