olivernn / poirot

mustaches in your rails
http://olivernn.github.com/poirot
108 stars 21 forks source link

Partials can be included using the same names on the server side and on the client side #27

Open lfjallstrom opened 11 years ago

lfjallstrom commented 11 years ago

This pull request makes it possible to include partials on the server side and on the client side using the same partial names.

To illustrate this, lets say we had partial _my_stuff.html.mustache. On the server side this partial needed to be included using {{> _my_stuff }}. However, on client side this partial needed to be included using {{> myStuff }}. The names of the partials on the client side was that same as the poirot rendering functions.

The second commit adds backwards compatibility for the old naming if that is needed.