Live data from Hacker News

Htmx is part of the GitHub Accelerator

htmx.org

221–230 of 520 posts

Re: Htmx is part of the GitHub Accelerator

#221
post #54

I've been a HTMX fan "since before was cool".. Very happy for the recent attention and "success". Also enjoying the shitposting and backlash mostly from the front-end crowd who believe the Web was invented in 2013 and they "made that city". :) I'm biased since the time Backbone.js came around, I understood part of the pain but was moderately skeptical, fast forward to React with the young energetic bros building dead…

Many of the ideas and concepts in htmx are things we worked on starting around 2012 at a top tier investment bank. Implementation details differ quite significantly, but the idea of hypermedia driven applications was core to everything we did. We unfortunately weren't able to win hearts and minds around these concepts in the long run, and blog driven development (a.k.a. cargo culting) replaced our efforts. I feel som…

Or it's because you weren't Facebook.

Like angular, react got the huge initial boost in popularity because of the brand behind it.

Re: Htmx is part of the GitHub Accelerator

#222
post #196

Earlier quoted context omitted.

> no such right exists; that would be like the right to rob with impunity No, it's the same kind of thing as having your records "sealed", to not let a past deed haunt you. Not even sure what kind of logic jumps one has to make to equate something like this to "robbing with inpunity". For starters the punishment to robbing isn't remembrance of your robbing, it's jail time or fine etc. And, fun fact, the aforementione…

while i disagree with what you say, i want to say that i really appreciate you saying something substantial and reasonable, rather than just repeating the vacuous moral-relativist nonsense that is the rest of this thread (i think your comment would be higher-quality if you also deleted your repetition of that vacuous nonsense, though, because it makes it harder to discuss the substantial issues here; there would be n…

>there would be no point in discussing ethical issues at all if moral relativism were correct (...) you wouldn't have bothered to post a comment at all if you were the nihilist you are posing as

This is wrong on several levels, including practical and philosophical (and those aspects of it have been covered a lot in moral philosophy).

For starters, whether morality is relative or objective has no bearing at all to whether it exists as a practical force in the human world - and thus whether it makes total practical sense to study it, shape it, apply it, benefit from it, use it to make things work smoother or more to your liking, and so on.

(Not to mention how it also makes sense to examine it, document it, and discuss it, from a curiosity or historical interest perspective, even if it doesn't concern one directly as a practical matter. People do study the morality of other historical periods or distant societies, for example, even if it has no impact on their life in their society).

Note that there are several other things for which exactly the same thing applies: religion, laws, taboos, and so on, even art and fashion.

>you wouldn't have bothered to post a comment at all if you were the nihilist you are posing as

Rejecting natural rights and understanding that rights are historical constructions doesn't mean one is disintered in rights.

I am very much interested in my right to my property, for example, and will vote, advocate, protest, demonstrate, etc, to maintain it.

I don't have to believe there's some inherent natural "right to property" for that. Just that I find the legal enforcement of one beneficial to me, and that I'd rather live in a society where it is enforced, as opposed to one where it's not.

Re: Htmx is part of the GitHub Accelerator

#223
So who is using this/hotwire/unpoly and something like capacitor or maybe react native wrapper or turbo-iOS to make “native” mobile apps that are mostly just web apps? Any good war/success stories?

I have to assume that just like most web apps don’t need aggressive SPA front ends, many mobile apps fall in the same boat…

Re: Htmx is part of the GitHub Accelerator

#224

Earlier quoted context omitted.

How so? (no snark, genuine) Your frontend makes a request to your server, the expectation is that will respond with html. If you have other services you need to bring in to the mix that responds with JSON then make the request to them from your server, have that parse the JSON in to HTML (most likely some kind of templating system like handlebars) and then send that back to your frontend as html for htmx to handle. O…

Dear god. Have we forgotten about the ACCEPT header? If you get a request with ACCEPT application/json, return json. If you get one with text/html, return html.

JSON APIs are typically more general. Here, you'll need different endpoints/handling for every flavor of HTML you may show that uses that same dataset. It's not so simple as Accept headers unless you always use exactly the same html, in every context on your site, to represent a "user with ID "

Re: Htmx is part of the GitHub Accelerator

#225
post #81
post #75

I've a hard time taking htmx serious for building a modern web app/site. It makes is impossible to build features that users have come to expect: * Faceted search with configurable filters, like filter date on before, between or after, but only show the filter if the user wants it. * Configure result view with different columns or even different views like maps or drawing something on a canvas like charts. You can ma…

Impossible is a strong word. I've looked at their API and I can certainly imagine ways to do everything you list above in HTMX. I would need to build and use it in anger to know if it's a good way to do so but I can imagine scenarios where it definitely is. The point about a JSON API is a good point and if you need a public API then you should probably factor that into your decision making but not everything has this…

    > The point about a JSON API is a good point
In a well-designed system, these two are not mutually exclusive but simply two facets of the same request pipeline. The JSON API simply serializes the model as JSON.

The HTMX-specifc API applies a template/transform over the model and returns HTML instead. If one thinks of hypertext as another serialization target, it's easy to see how one would easily be able to serve both JSON for pure APIs and hypertext for HTMX.

Re: Htmx is part of the GitHub Accelerator

#228

Earlier quoted context omitted.

Dear god. Have we forgotten about the ACCEPT header? If you get a request with ACCEPT application/json, return json. If you get one with text/html, return html.

JSON APIs are typically more general. Here, you'll need different endpoints/handling for every flavor of HTML you may show that uses that same dataset. It's not so simple as Accept headers unless you always use exactly the same html, in every context on your site, to represent a "user with ID "

Not at all. Post a form submission, send back either the same form with errors displayed, or simply return out-of-band updates to error message divs. You can redirect from the response as well using htmx, so if the form submission is successful, you can redirect to a success page ... or simply update a div with a success message.

If you get a request asking for json, you just return a json with the same thing. Not much changes with API design if you were designing the API well in the first place.

Re: Htmx is part of the GitHub Accelerator

#230
post #51

Earlier quoted context omitted.

Not at all. What makes you think that it looks like Angular?

Angular 1, I don't know about Angular 2 had syntax like ng-repeat {{action.text}}

There are a lot of frameworks/libraries/template-engines that use custom attributes and similar syntax and Angular definitely wasn't the first one.
Post reply on HN