Hey @Caspar_Jensen and welcome to the forum!
I use ChatGPT. I have the impression that it has gotten better and better, and I don't know if that is because of the memory it has of previous conversations, the model, or the way I have changed my prompting.
I tried using Claude, and I didn't find it as accurate as chatgpt, although I know of some other users in the forum that prefer Claude over chatgpt.
For me the key is always providing context, e.g.
- the data you want to manipulate, provide a snippet of the json
- the component you want to show the info in
- the result you want to see, providing also a snippet of how the json should look like.
- describing if you are using a js query or a transformer, and if a transformer, ask it to use curly brackets for variables
- describing if the code is an inline code in a component ( at the beginning I constantly had to ask to do it inline without constables, after a while it did it automatically)
I write most of my JS with the help of chat gpt, and I rarely have to repeat myself more than twice.
Hope this helps!