ripplejs/ripple

consistent plugin api

Opened this issue · 2 comments

I think we should follow a consistent plugin api like how rework, component/model, builder.js does:

var View = ripple(tmpl)
  .use(refs())

// instead of 
  .use(refs)

that way the plugin maker can add options later on without breaking backwards compatibility. It's also a pain to find out which ones uses the first method and which ones the second, especially when you use many plugins at once. What do you think?

Yeah that sounds good to me, mainly for backwards compatibility. I'll make the changes the various plugins.

+1 on this. I like the standard refs(), even if it looks a bit less pretty.