I am creating a ASP.Net MVC 3 application using Backbone.js. I am also using the jQuery templates for the views.
My question is how do I organize the files in an efficient way?
Currently I have a XXX.js file for the backbone application and inlined templates stored in the page that shows the backbone application, Index.cshtml. How can I move the templates into a different file that I can include like I include XXX.js?
App/
Scripts/
backbone.js
underscore.js
jquery-1.6.4.js
jquery.tmpl.js
myBackboneApplication.js
Views/
Home/
Index.cshtml
Controllers/
HomeController.cs
I would like to move the templates out of Index.cshtml and into something related to myBackboneApplication.js. Something that I can include as a file inside Index.cshtml instead of inlined.