abracadabra
recast
abracadabra | recast | |
---|---|---|
5 | 6 | |
731 | 4,825 | |
- | - | |
8.8 | 5.8 | |
6 days ago | 29 days ago | |
TypeScript | TypeScript | |
MIT License | MIT License |
Stars - the number of stars that a project has on GitHub. Growth - month over month growth in stars.
Activity is a relative number indicating how actively a project is being developed. Recent commits have higher weight than older ones.
For example, an activity of 9.0 indicates that a project is amongst the top 10% of the most actively developed projects that we are tracking.
abracadabra
-
Which library to use for AST manipulation?
I'm the author of Abracadabra, a VS Code extension that brings extra automated refactorings for JS & TS code.
- Extract Type automated refactoring in VS Code
- Automated Refactorings for JavaScript in VS Code
- "Toggle Braces" refactoring in VS Code
recast
-
What is an Abstract Syntax Tree in Programming?
GitHub | Website
-
[AskJS] Any good shortcuts for migrating off of enzyme?
If jscodeshift is confusing, I recommend looking into using recast directly, along with ast-types for AST traversal and its node factories. Inside your visitors, write some conditionals that check for the patterns you want to detect, then mutate the node passed to the visitor, or otherwise mutate the AST. Keep going until tests are passing.
-
Evan you on Svelte migration from Vue
I ended up writing my own codemod tool based on recast to automate most of the repetitive, mindless grunt work. Even with the tool shaving hundreds of hours off of the migration effort, there's still a huge amount of work left, since we need to find or create Vue 3-compatible alternatives of all of our Vue 2-only dependencies. Some of these dependencies (e.g. vee-validate) are used pretty ubiquitously too
-
Which library to use for AST manipulation?
I had great results with a combination of babel + recast. Babel is doing the job and Recast is mostly here to preserve the original style when printing code again. I animated a workshop @ Node.JS Montréal 2019 that was recorded here. We cover the parse/transform/print of code using Babel (live coding starts around 45').
-
JARVIS – Write me a Codemod
recast
- Show HN: Monocle – bidirectional code generation library
What are some alternatives?
vscode-glean - The extension provides refactoring tools for your React codebase
escodegen - ECMAScript code generator
vscode-live-server - Launch a development local Server with live reload feature for static & dynamic pages.
espree - An Esprima-compatible JavaScript parser
vscode-cpptools - Official repository for the Microsoft C/C++ extension for VS Code.
Acorn - A small, fast, JavaScript-based JavaScript parser
tabnine-vscode - Visual Studio Code client for Tabnine. https://marketplace.visualstudio.com/items?itemName=TabNine.tabnine-vscode
jscodeshift - A JavaScript codemod toolkit.
astx - Super powerful structural search and replace for JavaScript and TypeScript to automate your refactoring
ast-node-finder - AST Node Find api automatically generated from code
js-assistant - 120+ refactorings and code-assists for Visual Studio Code
ts-lite - Compiled TypeScript. Generates Go, Swift, Kotlin, WASM, Binary