5 ms·
I’m the creator of hyperscript and I’m happy to answer questions. I know it isn’t going to be everyone’s cup of tea, it’s probably even more divisive than htmx,
by recursivedoubts 3y ago
I’m the creator of hyperscript and I’m happy to answer questions. I know it isn’t going to be everyone’s cup of tea, it’s probably even more divisive than htmx, which I designed it to complement.
The big idea is a higher level and more expressive scripting language than js that embeds cleanly inline in html. It has integrated css query literals, relative location expressions (e.g. add .foo to the next .bar) and probably its most interesting feature, it resolves promises in the runtime so script writers don’t have to:
https://hyperscript.org/docs/#async https://hyperscript.org/docs/#async
The syntax is based on HyperTalk, the scripting language for HyperCard, which was one of the first programming environments I used when I was young.
Again, not for everyone but I enjoy using it and intend on getting it to 1.0 this summer after I get htmx 2 out the door.
- zachmu 3y agoI learned to code with hyper card and the examples give me a very warm fuzzy feeling
- sixdimensional 3y agoHtmx 2! 8)
- 8organicbits 3y agoWhat are your thoughts on error handling? The examples seem happy-path only. I find that code gets verbose once you handle errors, and things like backoff and retry.
- recursivedoubts 3y agohyperscript is designed for light, event-based scripting so we don't have a huge focus on error handling, but we do support a single catch/finally block per event handler or method: https://hyperscript.org/docs/#exceptions https://hyperscript.org/docs/#exceptions