Live data from Hacker News

Using Claude Code: The unreasonable effectiveness of HTML

twitter.com

81–90 of 308 posts

Re: Using Claude Code: The unreasonable effectiveness of HTML

#81
post #12

When exploring a new idea or tool, my go to prompt is ``` In a single index.html, no dependencies, sparse styling, create an app that ``` Even before AI, it's how I built small tools, and there's something lovely about being able to email my friends the tool, and tell them "If you want to make a change, toss it to your LLM!"

I recommend allowing AI to use TailwindCSS and Alpine in the context, as this would generate great lightweight dynamic web pages.

Re: Using Claude Code: The unreasonable effectiveness of HTML

#84
post #62

Earlier quoted context omitted.

I've yet to see Anthropic promote any sort of token optimization strategy to its users - they always assume we all have infinite inference. "No bread? Let them eat cake!"

Not sure how you use CC, but the last 6 months has felt like significant optimization efforts to me. Last year Claude would just read and edit files, now it's all kinds of basic tool gymnastics with grep/awk/sed/etc to narrowly slice and avoid token-heavy reads. Resuming sessions that aren't even that large get a scary prompt about using a significant portion of your token budget if you continue without compacting. T…

Valid points, but they address a totally different matter than the one I pointed out.

Re: Using Claude Code: The unreasonable effectiveness of HTML

#85

Both the original Markdown spec [1] as well as CommonMark [2] clearly specify support for inline HTML. With that you can kind of get the best of both words depending on your use case. For the most parts you just write the regular Markdown headers and paragraphs, embed images, insert tables etc without the need for any HTML tags, making it readable in source form. And if you want to embed an SVG file for example, whic…

You should never have to preview a markdown document, in my opinion. At that point, just make an HTML document.

Re: Using Claude Code: The unreasonable effectiveness of HTML

#86
post #33

Earlier quoted context omitted.

Is HTML really that much worse to edit than MD?

Let’s see… *No!* I mean, yes! It depends what we mean I guess, isn’t Markdown supposed to allow [hx]ml tags anyway if user need them? Then it’s more about asking the LLM to generate Markdown with this in consideration, and privilege rendering the output of reports in the preferred browser after relevant rendering.

1. I believe many applications that use markdown allow html. Others don't due to security/rendering issues.

2. One of the limiting factors of LLM is context. An html table takes up way more tokens than a markdown table. Especially if it's a WYSIWYG editor that has all kinds of css and tags just for fun.

Re: Using Claude Code: The unreasonable effectiveness of HTML

#87

Earlier quoted context omitted.

A counter argument would be that all programming languages of the last decades have been plain text based. No other more structured format has ever gained traction even though modern editors could be argued to be able to support that easily. Turns out, it doesn't actually work that way.

Most people edit documents in Microsoft word, though, so it didn’t seem too far fetched that LLM content would be edited similarly, especially as more and more non-programmers use it.

MS Word uses HTML under the hood, right? (Or some SGML at least.)

Re: Using Claude Code: The unreasonable effectiveness of HTML

#89

I’ve been prompting my way to all kinds of interactive HTML artifacts the last month or so. It’s way more fun than making decks and static documentation. I even did a workshop with PartyKit cursors, dot voting, reflection comments, and an individual rating at the end. Oh, and I can add super lightweight analytics so I know who actually reads my things or interacts with my prototypes. ^_^

Blog post plz

Just copy and paste the parent post into $yourFavouriteLLM and ask it to make a blog post for you to read about it. No need to ask the author to do more work than is necessary /s

Re: Using Claude Code: The unreasonable effectiveness of HTML

#90
post #73
post #34

Earlier quoted context omitted.

We have been authoring HTML by hand for decades with ease. Text editors are very good at it, and many have commands to auto-wrap, auto-close etc. Reading and writing is simple.

>We have been authoring HTML by hand for decades with ease No, we've been generating it with templates or authoring templates. Authoring HTML by hand is a very early 2000s thing to do.

After you a FE webdev that doesn't regularly author HTML by hand?
Post reply on HN