I recently undertook a significant project: migrating the entire JavaScript codebase of my AI Services plugin for WordPress (GitHub repository) to TypeScript.
Why is that significant?
- We’re talking about over 80 JavaScript files, so it’s by no means a small project. Not gigantic like e.g. Gutenberg, but certainly a substantial amount of code.
- Additionally, that JavaScript code is powering a plugin with a fairly unique feature set. This uniqueness often makes it harder for Large Language Models (LLMs) to assist, as there’s likely less similar code in their training data.
The process taught me a lot about the synergy between a well-structured codebase and LLMs. It also strengthened my belief that, while an LLM isn’t magically going to solve complex development tasks for you, it can be a massive productivity booster when you prepare your project and guide it effectively.
This post will walk you through how I used Cline in VS Code together with Google’s Gemini models to get it done efficiently and why I think this migration was worthwhile.