This is the configuration i'm using for my ui-router:
.state('parent', {
url: '/child1'
controller: ParentController,
abstract: true
})
.state('parent.child1', {
url: ''
})
.state('parent.child2', {
url: '/child2'
})
What I want to acheive ?
I want a /child1 url that I wanted to be default so I made the parent as abstract with child state url as 'empty'.
So I want that when user visits child2 state, the parent url gets replaced rather than appending it. How can i achieve that ?