Live data from Hacker News

Why AI Sucks at Front End

nerdy.dev

41–50 of 183 posts

Re: Why AI Sucks at Front End

#41

Ngl I’m reading this article after having used ai to build a beautiful front end that is pixel perfect. Yes ai can’t see, it only understands numbers. So tell it to use image magick to compare the screenshot to the actual mockup, tell it to get less than 5% difference and don’t use more than 20% blur. Thank me later. I built a whole website in like 2 days with this technique. Everyone seems to have trouble telling ai…

It's hard to interpret comments like this because we all have different standards and use cases. So it would really help if you could link to it. Even in a roundabout way if you want to avoid the impression of self-promotion.

Re: Why AI Sucks at Front End

#42
Design is an interesting beast.

Good design is not always logical. Color theory, if followed, results in pretty bad experiences. And interestingly, good design can't always be explained in a natural language.

Main thing is, it's very hard to get AI to have taste, because taste is not always statistically explainable.

The best I've gotten to is have it use something like ShadCN (or another well document package that's part of it's training) and make sure that it does two things, only runs the commands to create components, and does not change any stock components or introduce any Tailwind classes for colors and such. Also make it ensure that it maintains the global CSS.

This doesn't make the design look much better than what it is out of the box, but it doesn't turn it into something terrible. If left unprompted on these things, it lands up with mixing fonts that it has absolutely no idea if they look good or not, bringing serif fonts into body text, mixing and matching colors which would have looked really, really good in 2005. But just don't work any more.

Re: Why AI Sucks at Front End

#44

Earlier quoted context omitted.

Before I switched over the a career in tech, I made my living from music - playing live, session work, etc. Honestly, I'm probably one of the biggest skeptics when it comes to GenAI - but at least for music, the recent models (as in the past year) do not suck. They are actually really, really good for what it is. I have yet to hear anything truly original produced by those models. They seem to converge to the mean, a…

Rather than an existential threat, I could see it becoming it's own genre rather than infecting every other genre - when in the future people collectively realise it's kinda bad but has it's place as an almost retro aesthetic. Our idea of nostalgia was not that long ago. Also it could be generated on open weight local copyright free models that are super efficient in the future :P

There have been plenty of those is it AI or a real person music tests on the street you can find on YouTube. Almost no one knows which one is AI. There’s nothing there to be able to put them in different buckets.

Re: Why AI Sucks at Front End

#45
post #6

If you are really good at something, you'll find AI sucks at everything.

No you don't understand, AI is VERY BAD at front-end and CSS to the point you cannot use anything. It's not passable even slightly. Everybody with experience knows that FE has always been "harder" than BE - but BE the stakes are higher since it's the business. FE is often "just UI" and despite that being very important too, you can throw it away and start over a lot easier with a UI than you can with a BE platform. I…

Google Stitch is pretty awesome at front end layouts.

Re: Why AI Sucks at Front End

#46

Who says it sucks at front end? Unlike Stackoverflow, AI does a great job of "center a div." I tend to like working from reference documentation which is great for Python and Java but challenging for CSS where you have to navigate roughly 50 documents that relate to each other in complex ways to find answers. Like I don't give it 100% responsibility for front end tasks but I feel like working together with AI I feel…

CSS has definitely become a breeze to work with since LLMs have become a thing. Conceptually it's very "memorize how a billion possible combinations of obscure parameters interact with one another under various conditions" kind of setup so it's a perfect fit for machines and a terrible fit for humans. The main limitation I think is that they're blind as a bat and don't understand how things stand visually and render…

I'll grant that. A lot of times I want to give it a screenshot and say "here is what is wrong" and this is usually useless.

I will say though that multimodal capability varies between models. Like if I show Copilot a picture of a flower and ask for an id it is always wrong, often spectacularly so. If I show them to Google Lens the accuracy is good. Overall I wouldn't try anything multimodal with Copilot.

For that matter I am finding these days that Google's AI mode outperforms Copilot and Junie at many coding questions. Like faced with a Vite problem, Copilot will write a several-line Vite plugin that doesn't work, Google says "use the vite-ignore" attribute.

Re: Why AI Sucks at Front End

#47

I'm a backend dev and I'm always hearing about how LLMs are dramatically better at frontend because of much more available training data etc. Maybe my perspective isn't as skewed as I've been led to believe and LLMs need close supervision and rework of their output there too.

I would trust an LLM with backend much more than front-end. Especially if we're talking monolithic and good type system. Ideally compiled. When I say trust I mean it's not going to break the user-facing API contract, probably, even if internally it's a mess. If you let it do front-end blind, it will almost certainly embarrass you if you care at all about user experience.

Re: Why AI Sucks at Front End

#48
Everything is nuanced and generalizations help no one. There are absolutely frontend apps where AI straight up crushes. Sure these much be less novel apps but most of what people work on is a CRUD-esque interface.

Re: Why AI Sucks at Front End

#50

Ngl I’m reading this article after having used ai to build a beautiful front end that is pixel perfect. Yes ai can’t see, it only understands numbers. So tell it to use image magick to compare the screenshot to the actual mockup, tell it to get less than 5% difference and don’t use more than 20% blur. Thank me later. I built a whole website in like 2 days with this technique. Everyone seems to have trouble telling ai…

Yes can you share the front end that you created using this technique?
Post reply on HN