News for hackers. Stuff that matters.

khasan222

Re:Why AI Sucks at Front End on Sunday April 12, 2026 @10:27AM (#47740102)
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 how to check its work and that’s the real problem imho.

Truly if you took the best dev in the world and had them write 1000 lines of code without stopping to check the result they would also get it wrong. And the machine is only made in a likeness of our image.

PS. You think Christian god was also pissed at how much we lie? :)

It does indeed if it’s in plan mode, kind of just not as detailed. Me being an engineer I can spot certain things or question assumptions it may make

Ask HN: what’s your favorite line in your Claude/agents.md files?

What are some llm tips you’ve used to make software that is actually maintainable?I’ll go first. My new favorite line in my Claude.md. Helps me get around any ambiguity I have with my llm about what is being built or understood by tasks.CRITICAL: Always make detailed plan with sections for Analysis, specifications, to do list to achieve the spec, and a step by step manual testing strategy for...

( Read More... | 12 comments | 3 points | on HN )
Re:Switch to Claude without starting over on Sunday March 01, 2026 @08:56AM (#47206712)
It was amazing to me how bad cursor is with using the same model I use in Claude. Even with little knowledge on how to test the llms I was able to get very minimal mvps. But I find the real trick is to have the proper tools to reign in the ai.

Thorough CLAUDE.md, that makes sure it checks the tests, lints the code, does type checks, and code coverage checks too. The more checks for code quality the better.

It’s just a bowling ball in th hands of a toddler, and needs to ramp and guide rails to knock down some pins. Fortunately we get more than 2 tries with code.

Re:I made a down detector for down detector on Wednesday November 19, 2025 @09:36AM (#45980021)
Crying. I’m stealing this.
Re:America's Prison Population Is in Serious Decline on Thursday June 26, 2025 @12:40AM (#44384236)
I would argue that not having a male role model in your life is way worse than seeing the consequences enacted on another.

This even if their was a gain from watching others suffer, the lack of discipline, guidance, sternness, is way more detrimental than the positives of fearing the consequences

Re:My AI skeptic friends are all nuts on Monday June 02, 2025 @06:30PM (#44163889)
I find this very very much depends on the model and instructions you give the llm. Also you can use other instructions to check the output and have it try again. Definitely with larger codebases it struggles but the power is there.

My favorite instruction is using component A as an example make component B

Meh, maybe I'm standing too close to the problem, Idk. It is always frustrating trying to use a tool, and it not work though. I know it's free and all, but then I feel like helping people make good contributions is paramount in maintaining and fixing bugs.

Clearly the comma thing is a bug, it's the lack of wanting to fix it actually that is a bit disheartening, and why I think it is a deadish repo

That codebase definitely leaves much to be desired, I’ve already had to fork it for work in order to fix some bugs.

1 such bug, find a foreign language with commas in between numbers instead of periods, like Dutch(I think), and a lot of prices on the page. It’ll think all the numbers are relevant text.

And of course I tried to open a pr and get it merged, but they require tests, and of course the tests don’t work on the page Im testing. It’s just very snafu imho

Re:We're bringing Pebble back on Tuesday January 28, 2025 @06:54AM (#42851342)
Im not OP, but this sounds like the garmin instinct.
This is to me a non starter. Why does the server care what that im incrementing the local data? None of that is likely important until I am done.

This is just one more layer on top, and one more possible point of failure/frustration, as illustrated by this parent comment.

Re:jQuery v4.0 Beta on Wednesday February 07, 2024 @06:58AM (#39287464)
I’ve been writing JavaScript for 15 years professionally, and I must say this comment seems to be made by someone not as familiar with the context here. Moving away from React and frameworks like it would require a radical rethinking of what we expect to do with web apps. Building something like google maps, google docs, figma, are definitely doable with some of these tools, but it is almost impossible to maintain. This comment truly ignore the context of why frameworks like react took off. Jquery is great if you need a slideshow on a page, and maybe just some tracking, and even then, I’ve recently opted to just use vanilla js, with things like webpack build targeting whatever versions I would need. JavaScript programming is complex because making great ux can be a non trivial task.

Please excuse any typos, written on the phone

Re:Tell HN: GitHub no longer readable without JavaScript on Wednesday January 24, 2024 @08:32AM (#39117102)
It doesn’t? I’m confused I mean no one used pure HTML anymore everyone has at least some JavaScript GA is a JavaScript file that can be used to track people pretty reliably. Pure html nowadays is paradoxically harder to maintain though.
Re:Affirmative action at US colleges has been banned on Thursday June 29, 2023 @12:25PM (#36522626)
What I believe they’re trying to say is that it already has not been a meritocracy, and because of human nature that stain will always be there somewhat at least this is a attempted washing of the stain
Re:Plex lays off more than 20 percent of its staff on Wednesday June 28, 2023 @06:14PM (#36513389)
Plex really just needs to host instances of their servers at something reasonable that I can upload easily to. Add a torrent client for good measure. Just make stream boxes.
Re:Why the African genome project is so useful on Tuesday June 29, 2021 @06:39AM (#27674053)
I would ask when you ignore a problem does it go away? In my experience the answer is always no. You have to face a problem head on. The fact of the matter is people still experience racism all the time to this day.

No one should be asking you to hire someone simply because they’re of a different skin color. Most of the time in my experience people ask you to be more aware of you and how you feel, and to ask yourself am I doing this perhaps because of some unconscious bias I have?

Re:JavaScript Is Weird on Monday June 28, 2021 @07:43AM (#27660566)
Seems like this guy is just using a width a height difference to detect this. Also some ‘window.FireBug’ property, that doesn’t turn up much currently in chrome or ff console on Ubuntu
15+ hours of battery life on all of them? I would upgrade my machine for that alone.
Re:When FP? And When OOP? (2013) on Monday January 28, 2019 @10:07AM (#19017942)
I enjoy using a mix of the two. I find that some things are better expressed in OOP over FP, and will regularly mix them in the same code base. It lends itself to very nice code that doesn't force you to do anything but make it easier for someone who has never seen it to fix it.
Makes me wonder if this is something snapchat does whenever you look at some of their featured stories.
Re:Ask HN: What software do you use to take notes? on Monday April 10, 2017 @12:22PM (#14079850)
Workflowy. Simple and effective.