UI-Router evolves the concept of an AngularJS Route into a more general concept of a State for managing complex application UI states. Most notably, it allows nested state/view hierarchies and multiple named views.
0
votes
1answer
12 views
using tabs in a ui-router app without states for each tab
I'm currently developing an angular appp with ui-router and want to use tabs in one view. As typical tabs implementation involves using relative links (#tabId) it conflicts with ui-router state change....
0
votes
0answers
4 views
ui-router: persist state params when calling $state.go
There's a route param that represents the current site language, defined in the abstract app state.
angular.module("app", ["ui.router"]).config(["$stateProvider",
function($stateProvider) {
$...
2
votes
1answer
17 views
Angular ui-router resolve inheritance
I would like to create an abstract parent state, that has only one job: to resolve the current user through an ajax server call, and then pass this object to the child state. The problem is that the ...
0
votes
0answers
6 views
Ion-view gets title and ion-nav-buttons of previous view
The issue
I have a single <ion-view>, the roles view, that is not getting it's title set correctly or <ion-nav-buttons side="right> updated.
Instead it always picks up the title and ...
0
votes
1answer
34 views
How use controller variable inside a AngularJs directive
How use controller variable inside a directive . I used popoverHtml inside scope in directive but when i add type like this type not work :
like this : scope: { popoverHtml:'@', type: @ },
my html ...
1
vote
1answer
33 views
How to dynamically update popover content AngularJS Bootstrap
I use custom AngularJs directive for create bootstrap popover but when make popover popover content can't change and it's fix .
app.directive('nextLevel', function () {
return {
...
0
votes
0answers
5 views
ionic.leave do not fire
I want to in an a tab view to fire a function when leaving a tab. I saw 'ionic.leave' function, but it did not fire when leaving the tab. did I have to add something to the controler, ui-router or the ...
1
vote
1answer
16 views
Child route keeps triggering parent when ui-sref-active-eq is used (angular-ui-router)
I have a route in angular-ui-router that has child routes; I want links to those child routes to only be visible while on the parent route. They are present on a menu that is visible for the whole ...
0
votes
0answers
9 views
AngularJS ui-router always returning 404 on EJS files
First of all, I tried searching almost everywhere and may be I am still not clear about how to work with Angular ui-router and Express EJS templates. I'd much appreciate if you could help me out with ...
0
votes
0answers
17 views
$stateChangeSuccess does not fire on state change or page load
I have an app, loosely based on meanjs.org (changed to used HAPI and waterline). I will caveat, I don't code daily as career, so I'm not as proficient as many, but I love it, and I am proficient ...
0
votes
2answers
28 views
How to add the content `…<span class=“sr-only”>(current)</span></a>` into the HTML link when using Angular 2 **routerLink**?
Just wanting to know how include <span class="sr-only">(current)</span> on my clicked active link when using Angular 2 routerLink?
Example:
<ul class="nav nav-sidebar">
<li ...
1
vote
0answers
10 views
Failing to load the angular directive with in ionic project (plunker included)
I am trying to load the register directive inside the ionic project but strangely it doesn't load. Here is the plunker. Please point me in the right direction.
Example:https://plnkr.co/edit/...
0
votes
0answers
16 views
Angularjs state routing issue in firefox
When application loads index page it successfully routes to the page. But registering two times same url in browser history. So, Browser back button not navigating properly.
0
votes
1answer
9 views
changing states in ionic after state.transitionTo with notify false resets the scope variables
I have an ionic app where a user can select tag and then see the tagged content, when a user arrives in the app then we show the URL as follow
http://192.168.43.149:8100/#/explore
When user taps on ...
0
votes
0answers
7 views
Need help debugging ui-router: Unexpected end of JSON input
I'm getting an error (see below) when my Angular app initiates in the production environment
Problem: This sometimes prevents the initial state from rendering, leaving a blank page.
angular.js:...
0
votes
1answer
19 views
ui-router pass URL query parameters to controller via service - $stateParams values 'undefined'
Using ui-router and attempting to pass URL query parameters to the controller in the .config of the module, using a .service that has been injected into the resolve argument of the .state definition.
...
0
votes
1answer
16 views
How can I load a default template into an Angular ui-view
I'm delving into more advanced Angular routing options using ui-router. I've hit a bit of a problem with <ui-view>, specifically getting a nested ui-view to load with a default template.
I ...
0
votes
1answer
25 views
$state.go not changing for one specific state
For some reason, for just ONE state, it is not changing. I have no idea why it wouldn't work for one and not the others. I'm getting no response in the console at all.
I am also getting nothing from
...
0
votes
0answers
5 views
Angular RouterUI $location.search() vs $stateParams
With the use of Angular UI Router - you can access parameters url using $stateParams. Additionally, the $location service also has a way to access URL parameters: $location.search().param1
I know ...
0
votes
0answers
21 views
$state.go() keeps redirecting me to URL location and otherwise location
I have a $urlRouterProvider.otherwise('/login') in the routes so if it does not recognize the URL it goes back to the login page. after the user logins in I have a state.go() to another page in that ...
3
votes
1answer
47 views
html does not have access to object in controller angularjs
I want to show the object in view. The object itself is the controller, but the html does not have access to its properties (probably not see the model)! Maybe the problem ui routing?
app.js
(...
0
votes
2answers
38 views
keep user from going to other view ui-route
I am trying to add some sort of resolve/promise to this to keep the user from moving on to certain pages until they have created a profile, added a friend, etc. I have an app, a controller, and a ...
0
votes
1answer
43 views
How to get data from other states angular ui router
I'm trying to hide, show menu base on the data role in each state
.state('index.admin1', {
url: "/admin1",
templateUrl: "views/admin1.html",
data: {
pageTitle: 'Admin view',
...
0
votes
1answer
14 views
Custom directive not displaying withing a ui-view
I have a custom dircetive "3-test-directive" which I want to call to display a text. When I use this directive in the page partial-home.html, it does not diaplay me with any text from the directive(it ...
0
votes
1answer
28 views
angular 2 router.navigate undefined
Im trying to use navigate.route but keep running into this error: TypeError: undefined is not an object (evaluating 'this.router.navigate')
I can't seem to get this working so I was wondering if ...
2
votes
1answer
21 views
Angular + IE : State.go on button click not working
We are developing an angular app and are having trouble with IE / Edge. We do realize that angular dropped support for older IE versions, but we are fine with that.
Anyway, even in IE9+ and Edge we ...
1
vote
0answers
17 views
Firebase on auth allow access to views
I have set up Google Firebase email and password authentication. I am trying to deny access to my other routes except login/registration/forgot_pass routes. How can I limit the routes to authenticated ...
0
votes
1answer
24 views
Meteor - Call function before state loaded using ui-router
We're making a meteor app using angular and ui-router to control the states. We want to show a promo site if the user doesn't have access to the main part of the site. There will be a flag on the user'...
0
votes
0answers
23 views
Navigate to a route programatically in ui-router-ng2
I'm using ui-router-ng2 in an Angular 2 app. How do I tell the router, from JavaScript/Typescript, to navigate to a state? I'm looking for something like:
export class SomeClass {
constructor(...
1
vote
1answer
31 views
AngularJS Logout using $http then redirect
Right so I have a little dilemma here :).
I'm working on a project that is built with angularjs and Laravel. Login is done with laravel which is out of AngularJs "scope", should I say.
So in Front ...
0
votes
0answers
21 views
$stateChangeSuccess doen't be fired
I have tried to send pageview data to google analytics. And I'm using ui-router on angular.js. ui-router version is 0.3.1 stable.
So I added method run to handle $stateChangeSuccess but any state ...
-1
votes
0answers
23 views
change $urlRouterProvider.otherwise in controller in runtime
I use $urlRouterProvider.otherwise in config of my angular app for set otherwise path.
MetronicApp.config(['$stateProvider', '$urlRouterProvider', function ($stateProvider, $urlRouterProvider) {
$...
1
vote
1answer
16 views
Adding configuration file to Angular 1 how should the file be structured in order to use it
I have been wanting to have a central place for a configuration file with angular 1.5.8 that I can use for switching from JSON file to localhost to dev server and various other things.
I noticed $...
2
votes
1answer
21 views
Provide ui-router resolved resources without injecting directly into controller
I'm working on an angular 1.5 app that makes heavy use of ui-router.
We define our states like this:
$stateProvider
.state('jobs', {
url: '/jobs',
template: '<ut-jobs></ut-jobs>...
0
votes
1answer
21 views
AngularJS ui-router with templateProvider for A/B testing not rendering templates
I have created an angular app where I would like to randomly render two different homepage view when a user accesses the url.
I have created the app.js file with the following code using ...
0
votes
1answer
25 views
ui-router view is always same if I try new route while previous not resolved
I have a menu with ui-sref on items.
If I click on menu route '1', then click on menu route '2' before route '1' is resolved, then the view of route '2' gets stuck:
Now I click on menu item '3'. I ...
0
votes
0answers
21 views
Angular 1.5 components and ui-router 1.0: Add attributes to inserted dom element
In Angular 1.5, the .component() was introduced and seems to be considered good practice. I am currently migrating to ui-router 1.0 which allows (and recommends) routing to components.
So I refactored ...
0
votes
0answers
18 views
Angular ui-sref-active=“active” not working on refresh
I have the following link
<a data-ui-sref-active="active" data-ui-sref="contact" href="javascript:void(0)">
Contact
</a>
It shows as active when I go to that page by clicking the ...
-1
votes
0answers
16 views
how can i add a preloader until first state is completely loaded in ui-view?
I'm using ui-router to load the views in the index, but the first state takes to load a lot and i want to set a preloader to show it until the state finishes loading.
-1
votes
0answers
13 views
how to ignore (ui-route state) for hash '#'?
I need to ignore a state to hash, emits an error on the console.
console emit error (Could not resolve '#' from state 'app')
0
votes
2answers
42 views
asp net core with angular
I am having trouble finding a tutorial using asp net core with Angular 1 without using Razor. (I just want to use html) int the web project with a web api solution that will get the requests.
I have ...
1
vote
2answers
27 views
cannot switch between child state in angular ui.router
Following is my code and its codepen . I am unable to switch from nav4's child1 to child2, or child3, the url changes but the view doesn't, but after clicking on any child and then refreshing the ...
0
votes
1answer
17 views
Rejected resolve promise not caught
I am working partly from this post and this answer.
I have this route:
.state('barcodeQuery', {
url:'/barcode',
templateUrl: templatePath + '_BarcodeQuery.html',
controller: '...
0
votes
0answers
24 views
How to mask/hide parameter exposed via URL in angular-ui-router?
I've implemented Login with FB where I'm calling FB login API url with AUTHTOKEN variable in it. Facebook API actually authenticate user and redirect to my app url with the jwt token which will be in ...
1
vote
1answer
36 views
Not able to display the object array values in the dynamically inserted view using angular Js
I have just started to learn AngularJS.
I am trying to write this code with 3 files index.html and view1.html and view2.html . In index.html I have defined the module and controller function.In the ...
0
votes
0answers
13 views
Angular 1.5 using Angular 2 component router late time binding issue
I am having issues with passing variables to my child routes and rendering my page.
So to access my input values from the parent route I use $routerOnActivate. I then bind my parameter to my ...
1
vote
2answers
55 views
Angular ui-router: load values for data and params from service
I want to load data and params for each state once when the app loads from my service settings (this service returns also promise since data are loaded asynchronously).
Something like this:
.state('...
0
votes
0answers
20 views
How to add custom string to angular application url without effecting the normal functioning?
I have an angular application working with angular ui-router. When I run the application from server the url is like localhost/..../index.html
After I click on any state the url changes to
localhost/...
0
votes
0answers
12 views
AngularJS 1.4 states to 1.5 components migration and how to approach component based architechure
There are good articles that explains the significance of components and how to migrate existing directive to components with angularJS 1.5. I am working on a medium sized project with ui-router and ...
0
votes
1answer
24 views
How can I manage elements dependent on angular $state change when opening a new window on $state.href?
I have a specific angular view that needs to be opened in a new window without certain elements displayed (header/footer, etc).
At the moment I am achieving this by looking for the current state name ...