Answer the question
In order to leave comments, you need to log in
How and when is it better to load .js and .css files in an angular SPA application?
I have my own css and js file for each view, respectively, how and when to load it?
Here is the routing, but along with the template, you also need to load css and js files.
(function(){
angular.module("app", ["ngRoute"])
.config(function($routeProvider){
$routeProvider.when("/registration", {
templateUrl: "/templates/registration/form.html",
controller: "registrationCtrl"
});
$routeProvider.otherwise({redirectTo: '/registration'});
});
})();
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question