Replace InjectFlags with options object
Recipe ID
org.openrewrite.angular.migration.replace-inject-flagsArtifact@openrewrite/recipes-angularReplaces deprecated InjectFlags enum usage in inject() calls with the corresponding options object. For example, inject(MyService, InjectFlags.Optional) becomes inject(MyService, { optional: true }).
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.angular.migration.replace-inject-flagsIf the recipe isn’t available locally, install it with:
mod config recipes npm install @openrewrite/recipes-angular