ericf / express-handlebars

A Handlebars view engine for Express which doesn't suck.
BSD 3-Clause "New" or "Revised" License
2.31k stars 383 forks source link

Upgrade to Handlebars 3.0 #105

Closed ericf closed 9 years ago

ericf commented 9 years ago

This upgrades to Handlebars 3.0 and makes backwards-incompatible changes to the ExpressHandlebars API. Since Handlebars had a major version bump, it seemed appropriate for this package to have a major version bump as well, so I took the liberty of refactoring some things.

For most apps this will be a drop-in replacement to v1 of this package, and using Handlebars 3.0 should be a drop-in replacement as well. That said, here's the changes that potentially break back-compat:

dominicbarnes commented 9 years ago

One more request, {{@ExpressHandlebars.*}} is really verbose.. could you make the name a bit shorter? Maybe something like exphbs since that acronym is used elsewhere?

It's not a huge deal, maybe you could just make that property name configurable?

ericf commented 9 years ago

One more request, {{@ExpressHandlebars.*}} is really verbose.. could you make the name a bit shorter? Maybe something like exphbs since that acronym is used elsewhere?

Yeah it is, I'll sleep on it. exphbs seems like the top candidate.

It's not a huge deal, maybe you could just make that property name configurable?

I'd rather not add an option for this but instead keep it fixed, at least for now. So if the reason you want it configurable is to have a shorter name, I'd rather just change the name before I cut the release :smile:

dominicbarnes commented 9 years ago

Thanks!

Yeah, I just wanted the shorter name. Not to mention, having it capitalized like that just sticks out like a sore thumb in the apps I write. :P

ericf commented 9 years ago

I will be merging this in the next couple of days, so if anyone has feedback let me know.

adon-at-work commented 9 years ago

any timeline when it'll be merged to master? :)

ericf commented 9 years ago

@adon-at-work I hope to find time to finish this by updating the README docs and publishing to npm today.

adon-at-work commented 9 years ago

OK. Thanks.

ericf commented 9 years ago

Released as v2.0.0.