Ionic: Routing not working


#1

Hello, i need to make a routing system to my app. I made the abstract view, but it does not load any child view, how can i solve this? Below is the code of my app.js configuration.

**app.config(function($stateProvider, $urlRouterProvider) {

$stateProvider

// setup an abstract state for the tabs directive
.state(‘app’, {
url: ‘/app’,
abstract: true,
templateUrl: ‘templates/menu/menu.html’,
controller: ‘menuCtrl’
})

.state(‘app.principal’, {
url: ‘/principal’,
views: {
‘menuContent’: {
templateUrl: ‘templates/principal/principal.html’
}
}
});

// if none of the above states are matched, use this as the fallback
$urlRouterProvider.otherwise(’/app/principal’);

});**


#2

routing is ok… check whether the menuContent view name is defined or not


#3

It worked! Thank you.