TE
TechEcho
Home24h TopNewestBestAskShowJobs
GitHubTwitter
Home

TechEcho

A tech news platform built with Next.js, providing global tech news and discussions.

GitHubTwitter

Home

HomeNewestBestAskShowJobs

Resources

HackerNews APIOriginal HackerNewsNext.js

© 2025 TechEcho. All rights reserved.

A Haml-inspired mini-language for jQuery: Jabs

43 pointsby collintover 15 years ago

4 comments

tdavisover 15 years ago
I've yet to find a considerable value-add in Haml. With Sass the value is pretty clear -- CSS can benefit from having variables and functions to make scripts more reusable and easier to manage. As a Python user I'm a lover of significant whitespace, but with the ability to have my text editor auto-complete tags it isn't worth it to learn a new DSL just to save on some brackets.<p>With Jabs it's even harder for me to see the value; I'm required to learn a new syntax in order to remove some braces and add implied variables. The $ selector for instance removes all of four characters, two of which could be added automatically, if that's your thing. jQuery itself is already a rather terse library and with Jabs I'm adding yet another layer of abstraction and the need for compilation to writing JS.<p>The code is also harder to parse (for me) as a result of all the implicit variables. I suppose that isn't of much concern if you're just using it to write your own JS and nobody ever has to look at it, though. The ability (and probably frequent need) to mix JS and Jabs only creates a larger mess, I would imagine.
评论 #968363 未加载
评论 #968348 未加载
crayzover 15 years ago
And ruby's manifest destiny continues<p>Your current language is too ugly or verbose? There's a ruby DSL for that
评论 #968369 未加载
评论 #968566 未加载
collintover 15 years ago
I just recorded a screencast showing a quick example coding session for Jabs <a href="http://www.youtube.com/watch?v=JdnXJ6bj_qs" rel="nofollow">http://www.youtube.com/watch?v=JdnXJ6bj_qs</a>
评论 #968745 未加载
csmederover 15 years ago
Nice work!