Use case
Framework
Owner
React Router/6/UseHistory To UseNavigate
This codemod migrates
useHistory
touseNavigate
in React Router codebases. It replacesuseHistory
imports and updates all instances ofhistory.push
,history.replace
,go
,goBack
, andgoForward
to align with theuseNavigate
API.React Router/6/Switch To Routes
This codemod updates
Switch
components toRoutes
in React Router, in line with React Router v6 and newer. It also adjusts the imports, replacingSwitch
withRoutes
inreact-router-dom
import statements.React Router/6/Migrate StaticRouter Import
This codemod updates imports of
StaticRouter
to use thereact-router-dom/server
package instead ofreact-router-dom
, in line with updated React Router requirements.React Router/6/Replace UseRouteMatchWithUseMatch
This codemod updates
useRouteMatch
calls to the neweruseMatch
function inreact-router-dom
. It also adjusts any arguments passed touseRouteMatch
, changingstrict
toend
andsensitive
tocaseSensitive
. Additionally, it ensures that imports are updated to reflect the removal ofuseRouteMatch
.Webpack To Rspack/Cssextractwebpackplugin Community To Included Plugin
Handles the migration of the CssExtractWebpackPlugin webpack plug-in into an included plugin in rspack.
Webpack To Rspack/Migrate Update Babel Loader To Swc Loader
Using builtin:swc-loader offers better performance compared to the babel-loader and the external swc-loader, as it avoids frequent communication between JavaScript and Rust.
Styledictionary/4/Asynchronous Api
This codemod updates the following StyleDictionary class methods to be asynchronous:
extend()
,exportPlatform()
,getPlatform()
,buildAllPlatforms()
,buildPlatform()
,cleanAllPlatforms()
, andcleanPlatform()
. This ensures compatibility with the latest asynchronous workflows in Style Dictionary.Styledictionary/4/Asynchronous Api File Headers
This codemod updates the
fileHeader
format helper utility to be asynchronous, allowing support for async fileHeaders while maintaining consistency with the latest updates.Jasmine/V5/Handling Env Execute Callbacks
This codemod migrates
Env.execute
callbacks to await.Svelte/5/Svelte Element Expression
This codemod updates Svelte component definitions by transforming the
this
attribute in<svelte:element>
tags:Gatsby/V5/Removal UseNavigate Hook
Removal of useNavigate Hook
Removal UseNavigate Hook
Removal of useNavigate Hook
Nuxt/2/Convert Nuxt.Js Config To The `DefineNuxtConfig`
Convert Nuxt.js Config to defineNuxtConfig
Nuxt 2 Convert Nuxt.Js Config To `DefineNuxtConfig`
Convert Nuxt.js Config to defineNuxtConfig
Next/15/Refactor Imports From @Next/Font To Next/Font
Refactor Imports from @next/font to next/font
Sentry/V8/Remove Replay Package And Update Integration
This codemod removes the import statement for the @sentry/replay package and replaces instances of new Replay() with Sentry.replayIntegration(), aligning with the latest Sentry SDK practices.
TypeScript/V5.6/Add Test For Regex In Conditional
Add .test() to regex literals in conditionals
Node/Globmatch Native
This codemod automates the migration of glob-matching functions like
minimatch
,micromatch
, andpicomatch
to Node.js's nativematchesGlob
support in LTS version 20.17.0.Sentry/V8/Removal Sentry.ConfigureScope Method
This codemod facilitates the migration from Sentry version 7.x to 8.x by removing the deprecated Sentry.configureScope method. Instead, it transforms the code to utilize Sentry.getCurrentScope() for accessing and mutating the current scope. This change simplifies the API and aligns with the latest Sentry practices.
Jest Add Root And Assertions To Test
Added Input Root Test Cases to which handle the data disabled case