40 points · by desheikh · 17y ago · 9 comments
Also, a shoes-like syntax is already available in JavaScript, though it would be very hard to utilize as-is (in <JS 1.7, wrap in a function and use `var' instead of `let'):
app: {
stack: {
para("Foo 1"); // para as a function
para: "Foo 2"; // para as a label
button: {
let bar = new Button("Bar");
bar.onclick = function() { alert("Baz!") }
};
flow: {
style: ({ // CSS block
color: "red",
after: {
content: "!"
}
});
para("This is red and ends with an exclamation point");
}
}
}I called it Sandals and it's dead mainly because I'm lazy but also because I find it stupid to re-invent the wheel. YAY yet another UI toolkit to learn grumble
http://cloud.github.com/downloads/petejkim/socks/socks-chaos...
And the code: http://gist.github.com/113435