Skip to content
This repository has been archived by the owner on Jun 10, 2018. It is now read-only.

CoffeeKup as "helpers language" #27

Open
clyfe opened this issue Jul 20, 2011 · 0 comments
Open

CoffeeKup as "helpers language" #27

clyfe opened this issue Jul 20, 2011 · 0 comments

Comments

@clyfe
Copy link

clyfe commented Jul 20, 2011

I'd like to augment Eco, so that when a function object is given to output like so

<%- -> div class: 'big' %>

or even nicer

<%-> div class: 'big' %>

This function to be passed to the coffeekup compiler, if present.
This way, coffeekup becomes a nice DSL for view helpers.
Maybe have some API to plug different resolvers to different tags <%= <%- <%-> <%=> <%+> etc. ?

At the moment I know I can do

ck = coffeekup.compile
...
<%-ck -> div class: 'big' %>

But I'm mostly thinking at the zen of it.

PS.
Is Eco stream-able ? meaning does it "send" the resolved chunks of the template before the rest of the template is processed (like the recent Rails streaming additions) ?

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant