Questions tagged [angular-component-router]
85 questions
6
votes
2 answers
Router Resolver not rendering component
I have this router resolver to retrieve data from the Google Firestore. I am trying to use the Resolver to fetch the data ahead. When I place debugger at resolve function it shows me the data retrieved from the Server. But it is never returning from…

PopStack
- 171
- 1
- 8
6
votes
1 answer
Remove a component from history in angular 2
How could i restrict a component to load on back press.
Actually i have three component A(Normal Component), B(LoginComponent) and C(Otp Verification Component).
I'm routing to component B from A on some button click and from B to C to verify…

Ravi Sevta
- 2,817
- 21
- 37
4
votes
2 answers
Angular 2 components doesn't render correctly when used with router outlet
I'm developing a simple angular 2 website, using angular 2 lazy routing.
I use flickity slider to implement a slider in the home page,
the problem is :
when i declare the slider component in the app component (root…

Sid Ali
- 1,779
- 4
- 17
- 38
4
votes
1 answer
angular 1.5 component, ui-router resolve, $onChanges lifecycle hook
In the following example (plunker), a ui-router state routes to an app component that has a data object and a replace method that replaces this object with a new one using the given value. In its template, it has:
an editor component which triggers…

Pierre Kraemer
- 332
- 1
- 10
4
votes
0 answers
angular 1.5 component bindings, $onChanges hook & ui-router resolves
EDIT: I have reformulated this question here: angular 1.5 component, ui-router resolve, $onChanges lifecycle hook
I will illustrate my question with 3 successive examples.
In the first one, a so-called outer component owns a myData object that has a…

Pierre Kraemer
- 332
- 1
- 10
4
votes
2 answers
Angular JS 1.5 - I want to communicate between angular js components
I am trying to expose deletePhoto and editPhoto methods of businessPhotos components into verticalGrid component. But some how it is not accessible.
Any help would be appreciated, thanks
photo.js
angular.module('business')
…

shashank
- 439
- 1
- 4
- 17
4
votes
1 answer
How do I use AngularJS 1.5's Component Router in conjunction with user authentication?
I'm not quite ready to jump into Angular 2, but I wanted to tackle their new router and components.
For background, I am using a Python instance on Google App Engine that uses Endpoints in conjunction with Angular.
How do I use AngularJS 1.5's…

David Kirk
- 342
- 3
- 5
3
votes
1 answer
Angular 4: Custom Attribute Directive within not being executed
I am currently trying to create a custom attribute directive for my Angular 4 (v 4.2.6) application with component based routing. I have followed the official Angular guide on how to create such an attribute directive.
Everything works fine, when…

Simon
- 33
- 3
3
votes
1 answer
How can attach a route to the display of an ng-accordion panel?
I have an ng-accordion defined using an *ngFor loop, and I would like to adjust the location and bind a route to the view of a particular panel. Ideally, when a client clicks to expand a panel, the location would update in the browser and a new…

Deven Phillips
- 1,129
- 14
- 39
3
votes
0 answers
Implement smooth component transition animation when route change
how to implement smooth component transition animation when route change in Angular2 RC-1 ?
I am using angular component router (not the deprecated one).
I am fairly new to angular2 and typescript. Have some experience in Angular1.x

microchip78
- 2,040
- 2
- 28
- 39
2
votes
2 answers
How to display header Component only on certain pages in Angular (now it diplays only on reload)
I have an app that has a HomeComponent, where I don't want to show a HeaderComponent.
Also, I have other 4 routes where I do want to render the Header.
I could made it work, but there is a little bug when I navigate from HomeComponent, to any other…

Federico Rojas
- 37
- 1
- 6
2
votes
2 answers
Passing an object into Angular 9/10 resolver
I am stuck with passing object to the resolver in Angular 9/10. Any help will be deeply appreciated.
I have a page SearchUser.component.ts from where I am navigating to another page UserInfo.component.ts. I am trying to pass the object in the…

Suzane
- 193
- 1
- 3
- 13
2
votes
1 answer
How to pass down a callback from a parent component to a nested routed component?
I have the following format where I have a global component that has 3 nested components that are activated based on a given route:
$stateProvider
.state('create-goal', {
url: '/create-goal',
component: 'createGoal',
…

Detuned
- 3,652
- 4
- 27
- 54
2
votes
2 answers
How to detect route change in Angular 1.5 component router?
I am using angular 1.5 component router in my application. Is there a way to detect route change in component router. I want to run some code on route change.

Sushil Kumar
- 1,401
- 2
- 14
- 27
2
votes
1 answer
Angular 1 component router: Cannot read property 'startsWith' of undefined
I'm using Angular 1 component router and it works weired.
When I run website locally it works fine, but if I access it from another PC I receive js error
Cannot read property 'startsWith' of undefined
I tried to access website from 4-5 PCs and…

Madman
- 3,171
- 2
- 32
- 44