0

In one of my project, we haven't used any UI router and we have just used ngRoute. I have a requirement to build nested views, is it possible to acheieve nested views using ngRoute alone without any other libraries support? Kindly help me with some working example in the internet. Thanks for your help in advance.

JsLearner
  • 109
  • 1
  • 5
  • 16

1 Answers1

2

You can use the route-segment module. very easy to use. If you need more help let me know

IsraGab
  • 4,819
  • 3
  • 27
  • 46
  • If the answer/module helped you, please accept it. It gives feedback & it helps others – IsraGab Apr 05 '16 at 19:08
  • I need to acheive this using $route provider /$ngScope – JsLearner Apr 05 '16 at 21:06
  • Is it a question? Do you need some help? – IsraGab Apr 06 '16 at 17:39
  • @lsraGab Yes. I have a question on this issue. My detailed question as below http://stackoverflow.com/questions/36438211/angular-js-how-do-i-bind-ng-switch-which-is-outside-of-ngview-to-the-current-ro – JsLearner Apr 06 '16 at 18:03
  • Well I don't really get you. You're asking there about ng-switch and here about nested view. What do you you want to do (in a short sentence)? – IsraGab Apr 06 '16 at 18:12
  • Ok. I get it! (after reading one more time). You don't use ng-switch well. I suppose you read this answer: http://stackoverflow.com/questions/12232339/in-angularjs-can-i-use-current-route-in-ngswitch-outside-of-ngview – IsraGab Apr 06 '16 at 18:18
  • I just followed Andrew Juslin answer and it is not working for me :( – JsLearner Apr 06 '16 at 19:11
  • I answered you http://stackoverflow.com/questions/36438211/angular-js-how-do-i-bind-ng-switch-which-is-outside-of-ngview-to-the-current-ro/36462149#36462149 about how to deal with ng-view. If you look one more time at Andrew Juslin answer you'll understand that this is what he mean when he wrote `$scope.pagename = function() { return $location.path(); };` pagename get a value. This value then is checked by the `ng-switch-when="` statement (like a switch case). If you want to work with route it's another thing. The link I sent you is very detailled and clear. – IsraGab Apr 06 '16 at 21:00