Answer the question
In order to leave comments, you need to log in
Should PHP-level templating be mixed with JS-level templating?
People, welcome.
In my current activity, I actively use the ZF + Smarty bundle, but my soul lies more with one-page sites based on Backbone. Why it became interesting, is it possible to combine this approach?
Ideally I would like the following:
Answer the question
In order to leave comments, you need to log in
I have never worked with Backbone, so I may not understand some fundamental things, keep this in mind.
I once tried to do something similar, but came across a number of rakes. The main rake is storing the states of the components (and bringing the components to the required state). It turns out that either you are limited to stateless components, which is not always enough, or you store the state of the component in the URL, but then there is a conflict between the components on the same page and God bless you if you suddenly decide to conjure with this through the HistoryAPI, or you try to save the state of the components somehow else and build your own bike with all the consequences. The second problem is the isolation of components and, conversely, the exchange of data between them.
In fact, it all depends on what you need from the components. The less logic they have, the more feasible this scheme.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question