Frontend
You can write a better prompt. Your agent can make a better guess.
Alexander DEV Community
1 views
You are looking at a page thinking, "Move this down, use the same spacing as that card, but only on mobile." You know exactly what you mean because you're looking at it. Your coding agent is looking at a repository.
Your coding agent cannot read your mind
So you translate what you see into a prompt. Which element, which page, which breakpoint, this instance or every instance. Add a screenshot and the agent can see the pixels, but it still has to connect them to the right element, component, rule, and scope.
That's the guessing game.
For visual work, the useful context is already there when you make the change. You know the target, the property, the old and new values, the viewport width, and whether you changed one element or a shared rule. Throw that context away and you get to describe it all again in English.
This is the idea behind Pixy. Make the change on the running site and Pixy records the visual context for your coding agent. The agent still decides how to implement it because it has the repository and knows whether that 16px lives in Tailwind, a CSS module, a prop, or somewhere in globals.css you'd rather not discuss.
You already made the change. Describing it again just gives your agent another chance to misunderstand you.
Read original: https://dev.to/astroscout/you-can-write-a-better-prompt-your-agent-can-make-a-better-guess-2hni
← Previous
Hey DEV, I'm Vinayak — a CSE student who got tired of stopping at the notebook
Next →
Introducing ICU Studio - Fast and lightweight IDE for ICU messages
Related
Does this browser-focused/local-first project make sense?
Frontend
1
Reddit r/webdev
I Built a Passport Photo Maker Because a Visa Photo Took Me Two Hours
Frontend
2
DEV Community
10 AI Website Builders I Tested So You Can Skip the Trial and Error
Frontend
2
DEV Community
A decade of Rustls
Frontend
1
LWN.net
Comments0
No comments yet — be the first