The reason behind this is that, if we write our controller in some js file then compulsory that js file need to add in our page otherwise it will show you error.
Example:-
suppose i added my controller in js file called test.js then in whatever the page i want to use that controller then compulsory i need to add the js file like this,
<script src=".../test.js"></script>
and make sure before that add angular js file and our module file if exists.
0 comments:
Post a Comment