Live data from Hacker News

Ask HN: What novel tools are you using to write web sites/apps?

news.ycombinator.com

1–10 of 333 posts

Re: Ask HN: What novel tools are you using to write web sites/apps?

#3
Semantic HTML, CSS, Vanilla JS, and JAMStack.

Semantic: embed data directly in HTML. If I have a list of wines with categories, each wine's "class" attribute has a class for each category.

HTML: can be generated by anything and consumed by anyone. Great SEO.

CSS: These websites were all made with the same HTML, only CSS changing. http://www.csszengarden.com/

Let's imagine we have a checkbox, that when checked, should dim every wine that is not a white wine. Next to it is a div of wines, with the "container" class. The div contains wine elements.

3 lines of CSS:

    input[type="checkbox"].whiteWine:checked + .container > :not(.whiteWine) {
        opacity: 0.5;
    }
You can replace the checkbox's appearance with an image, a video, just about anything– it doesn't have to look like a checkbox.

This would take many lines of JavaScript in any other framework.

Instead of attempting to warp HTML into a UI library, this uses HTML as a data format, and CSS as a way to present that data.

Re: Ask HN: What novel tools are you using to write web sites/apps?

#4
I have been exploring offline-first approaches to building web apps.

In a nutshell, the UI interacts with local state, and a background service syncs local state with server-side state and vice-versa. This theoretically allows the app to remain fully functional even when offline, while maintaining the benefits of your stuff being accessible from all your devices. There's also UX gains as well - your UI interactions don't need to be blocked by network calls.

In practice, that means using something like IndexedDb to manage client-side state, and modelling data as CRDTs or similar in order to have eventual consistency with the server.

Re: Ask HN: What novel tools are you using to write web sites/apps?

#5
I am working on two alternative tools for building web apps:

https://htmx.org - uses HTML attributes and HTML-over-the-wire for AJAX/Web Socket/SSE interactions

https://hyperscript.org - an experimental front end programming language derived from HyperTalk that is event-oriented and that removes the distinction between synchronous and asynchronous code.

Both tools are HTML-oriented and are designed to be embedded directly in your HTML, rather than along side it. I am trying to popularize the term "Locality of Behaviour" for this idea:

https://htmx.org/essays/locality-of-behaviour/

There are a few tools that are moving people this direction these days, notably AlpineJS and Tailwinds.

Re: Ask HN: What novel tools are you using to write web sites/apps?

#6

Semantic HTML, CSS, Vanilla JS, and JAMStack. Semantic: embed data directly in HTML. If I have a list of wines with categories, each wine's "class" attribute has a class for each category. HTML: can be generated by anything and consumed by anyone. Great SEO. CSS: These websites were all made with the same HTML, only CSS changing. http://www.csszengarden.com/ Let's imagine we have a checkbox, that when checked, should…

IS CSS really this well featured and expressive these days? I havent tinkered with it in years.

Re: Ask HN: What novel tools are you using to write web sites/apps?

#8

I am working on two alternative tools for building web apps: https://htmx.org - uses HTML attributes and HTML-over-the-wire for AJAX/Web Socket/SSE interactions https://hyperscript.org - an experimental front end programming language derived from HyperTalk that is event-oriented and that removes the distinction between synchronous and asynchronous code. Both tools are HTML-oriented and are designed to be embedded dir…

on the same note, I'm really enjoying basecamp/hey's hotwire stuff together with go templates.

will be checking out htmx as well, thank you for the links.

Re: Ask HN: What novel tools are you using to write web sites/apps?

#10

I am working on two alternative tools for building web apps: https://htmx.org - uses HTML attributes and HTML-over-the-wire for AJAX/Web Socket/SSE interactions https://hyperscript.org - an experimental front end programming language derived from HyperTalk that is event-oriented and that removes the distinction between synchronous and asynchronous code. Both tools are HTML-oriented and are designed to be embedded dir…

"Locality of Behavior" is how everything started, when we used to embed PHP code into html. :)
Post reply on HN