Tag

codemod

1 views collected around this technical thread.

Rare Earth Juejin Tech Community
Rare Earth Juejin Tech Community
Sep 26, 2023 · Frontend Development

A Comprehensive Guide to Code Modification (Codemod) Tools and AST Transformations

This article explains the concept of codemod, outlines typical migration scenarios, details a step‑by‑step AST‑based workflow, and compares popular JavaScript code‑mod libraries such as Recast, jscodeshift, gogocode, and ast‑grep, helping developers choose the right tool for automated code upgrades.

ASTGoGoCodeJavaScript
0 likes · 13 min read
A Comprehensive Guide to Code Modification (Codemod) Tools and AST Transformations
Sohu Tech Products
Sohu Tech Products
Mar 10, 2021 · Frontend Development

Applying jscodeshift Codemods for Large‑Scale Frontend Refactoring

This article explains how to use codemod tools, especially jscodeshift, to automatically refactor a growing frontend codebase by replacing a monolithic constants package with per‑constant imports, covering the underlying AST concepts, step‑by‑step script creation, and practical CLI usage.

ASTJavaScriptcodemod
0 likes · 11 min read
Applying jscodeshift Codemods for Large‑Scale Frontend Refactoring
ByteFE
ByteFE
Mar 2, 2021 · Frontend Development

Using jscodeshift Codemod to Refactor Large‑Scale Frontend Projects

This article explains how to create and run a jscodeshift codemod that transforms imports of a bulky constants package into per‑constant imports, reducing bundle size in large frontend codebases by leveraging AST parsing, AST Explorer, and automated code modifications.

ASTcodemodfrontend
0 likes · 16 min read
Using jscodeshift Codemod to Refactor Large‑Scale Frontend Projects
NetEase Cloud Music Tech Team
NetEase Cloud Music Tech Team
Sep 2, 2020 · Mobile Development

Rebuilding NetEase Cloud Music's React Native Infrastructure: From 0.33 to 0.6, Automated Deployment, Codemod, and Multi‑Platform Strategy

NetEase Cloud Music rebuilt its React Native stack from version 0.33 to 0.6, introducing automated one‑click deployment, a custom codemod that migrated all apps in a day, and a three‑platform toolchain that unified iOS, Android, and web, boosting checkout reach to 99% and scaling to over ten production RN applications.

Automated DeploymentCross-PlatformFrontend Engineering
0 likes · 14 min read
Rebuilding NetEase Cloud Music's React Native Infrastructure: From 0.33 to 0.6, Automated Deployment, Codemod, and Multi‑Platform Strategy
Tencent IMWeb Frontend Team
Tencent IMWeb Frontend Team
Aug 16, 2016 · Frontend Development

How to Automate JavaScript Component Refactoring with jscodeshift

Learn how to use Facebook’s jscodeshift tool to write codemods that automatically rename lifecycle methods in JavaScript components, with step‑by‑step examples, test setup using AVA, and detailed AST traversal logic for precise transformations.

ASTAVAJavaScript
0 likes · 5 min read
How to Automate JavaScript Component Refactoring with jscodeshift