I’m pretty new to js and jQuery, I can read most of the code but I do not understand most of the more advanced concepts.
Routing like _main.js does is completely new to me…
It does seems an amazing aproach and something I do really want to learn but as it stands now I have two doubts (only two, because I haven’t ventured a lot into it yet more doubts will follow!)
- How can I load a script based on a page template? (not based on page name or url).
- If I load a script based on the page (for example ‘contacts’) will it work with WPML like urls (like site.com/en and site.com/it)?
Any resources you could point me to read on this topic will be welcomed (on the Routing topic )