3 ms·
Thought the exact same when I first started using it, then realised the benefits of the syntax: 1. It allows for the "async transparency" feature to work! 2.
by geenat 4y ago
Thought the exact same when I first started using it, then realised the benefits of the syntax:
1. It allows for the "async transparency" feature to work!
2. It enables first class event handling in a much less verbose way than Javascript. Unlocks the power of the native event system.
3. Less verbose ways to do Locality of Behavior.
You get a number of escape hatches, and hyperscript is capable of being mixed with javascript:
Call javascript directly
_='on click call alert("Javascript called directly")'
Embed javascript directly
_='on click js alert("Javascript mixed in hyperscript") end'
Next release will bring javascript comments to make learning and migrating blocks of code easier.
// and /* ... */
Also I must say you do get used to the syntax relatively quickly.
- ksec 4y agoI am thinking if it could be more hybrid. It seems to move too far to the "General English" spectrum. If we could replace the most common syntax with 2 to 3 symbols to balance things out.
- mrtweetyhack 4y ago