← All recipes
Moderne licensed

Replace getDOMNode() with React.findDOMNode()

Recipe IDorg.openrewrite.react.16.find-dom-nodeArtifact@openrewrite/recipes-react

Migrates deprecated getDOMNode() calls to React.findDOMNode().

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.16.find-dom-node

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

mod config recipes npm install @openrewrite/recipes-react