@anmolarora wrote:
Hello Everyone I just noticed a problem with ion-nav-bar which appears when using directives as templates with ui router. Being precise, when using state router as - .state('tab.home', { url: '/home', views: { 'tab-home': { template: '<home></home>' } } })
Where is a reusable compnent/directive with it's own ion-view and ion-components.
angular.module('myapp.Directives').directive("home",[function () { return { restrict: "E", replace: true, templateUrl: 'views/home.html', scope: { }, bindToController: { }, controllerAs: "shiftCtrl", controller: function ($scope) { //controller code here } } }])
Everything seems to be working fine until I use or in the definition of 'home.html' because these don't work at all. However, when I define state like -
.state('tab.home', { url: '/home', views: { 'tab-home': { templateUrl: 'views/home.html', controller: 'HomeCtrl' } } })
The nav buttons and nav title work fine in this case.
I have tried a couple of tweaks but none of them seems to work. Can someone please help me fixing this issue?Thanks
Posts: 1
Participants: 1