Ask HN: How are you getting decent front end interface results out of LLMs?

I find in my workflow LLMs do a pretty excellent job of generating backend code, but whenever I get them to build a new bit of an interface on an existing website they do all sorts of wonky stuff. They ignore existing styles and write their own, they build custom javascript in places that we already have working solutions, they fail to properly align elements, pick random colours, random font sizes, etc, etc. Do you guys have some magic to avoid this madness?

2 points | by VladVladikoff 7 hours ago

1 comments

  • RG86 6 hours ago
    Hey,

    I usually tell it very strongly the rules I want it to follow and make sure it writes it to memory. I've also found that when you tell it to use specific components from a library or framework, it does a very decent job.

    Extra points if the library/framework has a MCP server or skill available.