←back to thread

9 points thebordella | 1 comments | | HN request time: 0.219s | source

As an Old, I came up learning the OG web dev languages - HTML, CSS, JS, PHP, etc. As a solo dev, I still largely work with these as natively as possible. But I am not a total dinosaur. I embraced jQuery in the early 2000's, Bootstrap scaffolding, and now often build reactive UI's using Vue 3.

Still, I continue to be picky about the many abstractions-of-abstractions that litter the dev landscape, mostly devised to drive their founders' business models.

AI-driven co-pilots are red hot now, and I want to evaluate their usefulness to my style of dev work. I've begun dabbling with services like Codeium and Claude, particularly within VSCode.

At first these AI tools seem exciting. A whole function conjured out of thin air from a short prompt! But the more I test drive, the more I find that I'm spending my time trying to craft prompts that are accurate enough to generate the code I want. Whereas I could be using that time to just conceive and write the code myself.

If you are not already well-versed in your coding languages, these AI tools must save a ton of time and effort. My question is - what about you devs who are already proficient in your languages of choice? How do you leverage AI co-pilots to maximize their usefulness without just falling into the "distracted by another abstraction" hole?

1. solardev ◴[] No.42178843[source]
I guess I'm an "ancient" then, having done web dev since the first Netscape Navigator. I use ChatGPT all day, every day for mundane tasks:

1. As a Google/Stack replacement, asking complex queries in natural language with many follow-ups. It's really good at helping me understand complex topics step by step, at an appropriate level of detail.

2. To help me with the syntax I can never remember (like different combinations of TypeScript types and generics and explaining what it all means). I feed it three or four types and tell it "I need a fifth that inherits X from here, Y from there, and adds Z, which can be blah blah blah..." and it's really good at doing that and then also teaching me the syntax as it goes.

3. To write in-line JSDoc/TSDoc to make my functions clearer (to other devs). At work we have a largely uncommented codebase, and I try to add a bunch of context on anything I end up working on or refactoring.

4. To farm out some specific function, usually some sort of nested reducer that I hate writing manually or cascading entries of Object.entries() with many layers.

5. Ask it higher-level architectural questions about different frameworks or patterns, and treat it as a semi-informed second opinion that I always double-check.

Generally speaking, it's really pretty good at most of this. I manually read through and verify everything it produces line-by-line and ask it for corrections when I notice them. It's still a lot faster than, say, trying to code review a true junior dev's work. It's not quite as efficient as being able to easily talk shop with another experience dev, but it's rare for me (in my jobs) to have a lot of experienced devs working on the same feature/PR at once anyway, so compared to someone jumping into a branch fresh, ChatGPT is a lot better at picking up the context.

---------

I do NOT:

A) Use an in-IDE AI assistant. Copilot was hit or miss when it came out. It was great at simple things, but introduced subtle flaws in bigger things that I wouldn't always catch until later. It ended up wasting more time than it saved. The Jetbrains AI assistant was even worse. Maybe Claude or Cursor etc are better, I dunno, but I don't really need them. I love Webstorm as it is, without AI, and I can easily alt-tab to ChatGPT to get the answers I need only when I need.

B) Use it to write public-facing documentation. While it can be good at this, public-facing stuff demands a level of accuracy that it can't quite deliver yet. Besides, I really enjoy crafting English and don't want a robot to replace that yet :)

Overall, it's a huge time saver for sure. I expect it to fully replace me someday soon, but for now, we're friends and coworkers :)