I have used the Asp.net MVC 5 Razor and angularjs. Now my view have the layout .That layout contains top and side menu bar. So when the view load i got nested page top and side bar in the ng-view.How do i resolve this.
If i was tried with another one root view and removed the layout.that was worked fine.but when i hit F5 loaded the action alone.Master content is missed
_Layout.cshtml
<header ng-include="'/Partials/TopNavbar'" class="topnavbar-wrapper"></header>
<!-- sidebar-->
<aside ng-include="'/Partials/Sidebar'" ng-controller="SidebarController" class="aside"></aside>
<!-- offsidebar-->
<aside ng-include="'/Partials/Offsidebar'" class="offsidebar"></aside>
<!-- Main section-->
<section>
<!-- Page content-->
<div ui-view="" autoscroll="false" ng-class="app.viewAnimation" class="content-wrapper">
Tested
<div ui-view="" data-autoscroll="false" class="wrapper">
@Styles.Render("~/bundles/bootstrapStyles")
@Styles.Render("~/bundles/appStyles")
@RenderBody()
@Scripts.Render("~/bundles/baseScripts")
@Scripts.Render("~/bundles/appScripts")
</div>
</div>
</section>
<!-- Page footer-->
<footer ng-include="'/Partials/Footer'"></footer>
View
@{
// This is requried for AngularJS because we have to send only the view markup (not within the layout)
Layout = "~/Views/Shared/_Layout.cshtml";}
<small>Subtitle</small>
<div class="row">
<div class="col-lg-12">
testing A blank template
</div>
</div>
This view has refered the layout. So while page load the Master content loaded perfectly.but when the ng-view load again the master content loaded like nested.
ng-view
orui-view
? tag isng-view
& code saysui-view
– Pankaj Parkar May 26 at 13:42