It does help in a specific case: where I need to write a very obvious but repeated/time consuming self-contained component.
I do know how to write it, but I don't want to write boilerplate stuff again and again, and I want to manage time efficiently. That's when I use, say, ChatGPT to create a React component that is circular and has a click handler (just an example).
I know how to do it, I know how it works, I just want to do it faster.
And I can verify that it works by simply using the component and seeing it works.
Though this is React and frontend. I would probably not blindly do the same for a database connected entity deletion endpoint at a backend.
For me the advantage is that for simple cases like the one you mention, it will hardly ever make dumb mistakes like misspelling a CSS property name or missing the return keyword. So it will not only type faster than me, but it often bypasses the "OK, it's not working, let see what I missed" phase.
This high-level approach usually breaks down for more complex scenarios, but for those, you can often explain with some detail how you want the code to look like, and it will give you the code and auto-correct any glaring mistakes you made.
I do know how to write it, but I don't want to write boilerplate stuff again and again, and I want to manage time efficiently. That's when I use, say, ChatGPT to create a React component that is circular and has a click handler (just an example).
I know how to do it, I know how it works, I just want to do it faster.
And I can verify that it works by simply using the component and seeing it works.
Though this is React and frontend. I would probably not blindly do the same for a database connected entity deletion endpoint at a backend.