Assess, plan, evolve.
Reusable compiler-aware skills that help coding agents understand, plan, and safely evolve your codebase.
40 packages
This codemod moves the client-related configuration parameters (ignore, headers, requestTimeout, and maxRetries) from the API object to the second options object. ## What Changed Previously, ignore, headers, requestTimeout, and maxRetries could be passed directly inside the API object. Now, these parameters need to be specified in a second options object. Now, both callbacks and promises return an object containing body, statusCode, headers, warnings, and meta. ## Before ```jsx const body = await client.search({ index: 'my-index', body: { foo: 'bar' }, ignore: [404] }); client.search({ index: 'my-index', body: { foo: 'bar' }, ignore: [404] }, (err, body, statusCode, headers) => { if (err) console.log(err); }); ``` ## After ```jsx const { body, statusCode, headers, warnings } = await client.search({ index: 'my-index', body: { foo: 'bar' } }, { ignore: [404] }); client.search({ index: 'my-index', body: { foo: 'bar' } }, { ignore: [404] }, (err, { body, statusCode, headers, warnings }) => { if (err) console.log(err); }); ```
- elasticsearch
- 8
- +1
Migrate ESLint configuration from v8 to v9 flat config format
- transformation
- migration
- +3
Conservative Spring Framework 7 Java migration codemod that rewrites exact-safe API, annotation, configuration, and compatibility-branch patterns under main and test Java source sets.
- upgrade
- breaking-change
- +3
Backstage 1.53.0: Rename experimental CIMD auth configuration key
- backstage
- migration
- +4
Run this codemod to upgrade configuration files that need to be changed after migrating from `mocha` to `vitest`. ## Example ### `package.json` ### Before ```json { "name": "package-name", "dependencies": { "mocha": "^10.2.0", "some-mocha-plugin": "^10.0.4" }, "devDependencies": { "mocha": "^10.2.0", "@types/mocha": "^10.0.4" }, "main": "./dist/index.cjs", "scripts": { "test": "mocha" }, "mocha": { "config-key": "config-value" }, "files": ["README.md", ".codemodrc.json", "./dist/index.cjs"], "type": "module" } ``` ### After ```json { "name": "package-name", "dependencies": {}, "devDependencies": { "vitest": "^1.0.1", "@vitest/coverage-v8": "^1.0.1" }, "main": "./dist/index.cjs", "scripts": { "test": "vitest run", "coverage": "vitest run --coverage" }, "files": ["README.md", ".codemodrc.json", "./dist/index.cjs"], "type": "module" } ``` ### `tsconfig.json` ### Before ```json { "compilerOptions": { "types": ["mocha"] }, "include": [ "./src/**/*.ts", "./src/**/*.js", "./test/**/*.ts", "./test/**/*.js" ] } ``` ### After ```json { "compilerOptions": {}, "include": [ "./src/**/*.ts", "./src/**/*.js", "./test/**/*.ts", "./test/**/*.js" ] } ``` ### `.mocharc` ### Before ```json { "loader": ["ts-node/esm"], "full-trace": true, "failZero": false, "bail": true, "spec": "./**/test.ts", "timeout": 5000 } ``` ### After `Removed`
- migration
Backstage 1.55.0: Move Connections configuration imports and re-exports to @backstage/connections/config
- backstage
- migration
- +4
Backstage 1.46.0: Migrate Valkey cache configuration to new native options
- backstage
- migration
- +4
Replace Cipher.getInstance(AES) with explicit Cipher.getInstance(AES/CBC/PKCS5Padding) configuration
- security
- encryption
- +3
This codemod automates the process of splitting your TanStack Router route files into two separate files to enable code splitting. By utilizing this codemod, you can easily move non-critical route configuration, such as the component, into a separate `.lazy.tsx` file, which allows for better performance and reduced initial load time in your React application. ## Before Code Splitting In the original setup, all route configurations, including critical and non-critical parts, are contained within a single file. ```tsx // src/routes/posts.tsx import { createFileRoute } from '@tanstack/react-router'; import { fetchPosts } from './api'; export const Route = createFileRoute('/posts')({ loader: fetchPosts, component: Posts, }); function Posts() { // ... } ``` ## After Code Splitting After running the codemod, the route configuration is split into two files: ### Critical Route Configuration The critical part of the route configuration remains in the original file: ```tsx // src/routes/posts.tsx import { createFileRoute } from '@tanstack/react-router'; import { fetchPosts } from './api'; export const Route = createFileRoute('/posts')({ loader: fetchPosts, }); ``` ### Non-Critical Route Configuration The non-critical part, such as the component, is moved to a new `.lazy.tsx` file: ```tsx // src/routes/posts.lazy.tsx import { createLazyFileRoute } from '@tanstack/react-router'; export const Route = createLazyFileRoute('/posts')({ component: Posts, }); function Posts() { // ... } ```
- tanStackRouter
- CodeSplitting
Convert Nuxt.js Config to defineNuxtConfig This codemod helps you migrate your Nuxt.js configuration files to use the new `defineNuxtConfig` format. This is useful when updating to a newer version of Nuxt.js that supports this method for defining configuration. The codemod transforms the existing `export default` Nuxt.js configuration objects into the `defineNuxtConfig` function call. This standardizes the configuration format and ensures compatibility with the latest Nuxt.js features. Example Transformations Below are some examples demonstrating how the codemod transforms the configuration: ### Example 1 **Before:** ```ts export default { // ... }; ``` **After** ```ts export default defineNuxtConfig({ // ... }); ```
- nuxt
Convert Nuxt.js Config to defineNuxtConfig This codemod helps you migrate your Nuxt.js configuration files to use the new `defineNuxtConfig` format. This is useful when updating to a newer version of Nuxt.js that supports this method for defining configuration. The codemod transforms the existing `export default` Nuxt.js configuration objects into the `defineNuxtConfig` function call. This standardizes the configuration format and ensures compatibility with the latest Nuxt.js features. Example Transformations Below are some examples demonstrating how the codemod transforms the configuration: ### Example 1 **Before:** ```ts export default { // ... }; ``` **After** ```ts export default defineNuxtConfig({ // ... }); ```
- nuxt
Backstage 1.53.0: Migration recipe for the deprecated experimental CIMD configuration key.
- backstage
- migration
- +4
Ready to evolve your codebase?
Build tailored, compiler-aware skills to assess, plan, and automate complex codebase changes.