I made a big mistake and designed the whole master page and its pages inside a view without a nested structure in my single page angular application. And now, I need a login page with a totally different structure and it's a bit time consuming to change the templates and add a root page.
I'm looking for a way to navigate (or redirect) to my login page but I want my login page template to fit the whole page instead of fitting inside the ui-view.
Is this possible?
<p>I don't want this paragraph in my login</p>
<div ui-view></div>
var loginState =
{
name: 'login',
url: "/login",
// root: ? there should be no root for this
templateUrl: 'app/access/login.html',
controller: 'LoginPageController',
resolve: {
deps: ['$ocLazyLoad', function ($ocLazyLoad) {
return $ocLazyLoad.load([{
name: 'App',
files: [
"app/LoginPageController.js"
]
}]);
}]
}
}
app.config(['$stateProvider', '$urlRouterProvider', '$locationProvider',
function ($stateProvider, $routeProvider, $locationProvider) {
$routeProvider.otherwise("/dashboard");
$stateProvider.state(dashboardState).state(testState)
.state(loginState)