when the index page load with ui-view,the injected view works fine But when i change the state and the new view injected it's not get the functionality that define in app/app.js & all.js which loaded initially with the main view.Although the injected ui view gets the css file but not js file which loaded earlier with the main index.html.
here is the index.html and config.js
Asked
Active
Viewed 194 times
1

Nazmul
- 143
- 14
-
No idea what *"not getting the javascript file"* means. Provide better detailed problem description – charlietfl Jun 25 '16 at 12:53
-
@charlietfl i have tried to explain clearly to you.. Now u can see. If anything else u need just cmnt. – Nazmul Jun 25 '16 at 13:22
-
Please add information from the console, which error is throwing you? – Paulo Galdo Sandoval Jun 25 '16 at 15:23
-
@PauloGaldoSandoval no error is throwing. Due to not getting the all.js and app.js that loaded with index.html. the ui-view not performing some functionality that defined on that all.js & app.js script. Though the network shows those two js file already loaded. but ui-view don't get them. it's similar to this problem http://stackoverflow.com/questions/18220197/angularjs-does-not-load-scripts-within-ng-view – Nazmul Jun 25 '16 at 15:53
-
Your urlRouterProvider redirect to `/index` but i didn't see any state like that. – Paulo Galdo Sandoval Jun 25 '16 at 16:04
-
@PauloGaldoSandoval /index state is define below but i didn't attach that on screen shot. Besides it's not necessary because it's not going to /index , the desire ui-view is injected, problem is some of the functionality of that view not working that is define of all.js & app.js. – Nazmul Jun 25 '16 at 16:10
-
1uhm sound stupid, but you tried to put your all.js and app.js after jquery and angular dependency's? they are declared before, if them use a angular o jquery component they wont load properly. – Paulo Galdo Sandoval Jun 25 '16 at 16:16
-
@PauloGaldoSandoval may be ur right and already i have tried that before posting the question , it didn't work. – Nazmul Jun 25 '16 at 16:19