Questions tagged [angular-ui-router]
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.
angular-ui-router
10,450
questions
0
votes
0
answers
38
views
Cannot fix HttpClient Error in Angular Project
I am trying to set up a runtime configuration value for a URL in my angular project how it is outlined in this thread, and I can't seem to figure out why i am getting a NullInjectorError: ...
0
votes
0
answers
29
views
Ionic Angular TypeError: this.router.navigate is not a function
i am making a API call after the QR code scan,in the qr code row value my api url is present after the successfully fetching data i want to redirect to registration page but the following error is ...
0
votes
1
answer
62
views
Error NG0303 Can't bind to '*ngIf' since it isn't a known property of 'nav' - Angular 18
I am creating a project in Angular 18. For now, I am only working on the frontend, but I need to create a "test" login. The problem I have is that the navbar was showing in my "login&...
0
votes
0
answers
16
views
Display Sub Application UI in Main Application MasterLayout in Angular
My Angular application has Main Application and Sub Application.
Main application loads with Master layout having Menu on left side shown below
URL when click on Menu options available in Main ...
1
vote
1
answer
53
views
Access child components through <router-outlet> tag in Angular 17
In my app.routes.ts,
export const routes: Routes = [
...
{
path: "student",
component: StudentComponent,
children: [
{
path: "first-component",
...
1
vote
1
answer
44
views
How to get value before calling .forRoot?
export function getApiKey(config: WebConfigService): Promise<boolean> {
return new Promise((resolve, reject) => {
config.getConfigLoaded().subscribe(key => {
if (key) {
...
1
vote
1
answer
174
views
Web Routing in Angular 17
I have a routing file written as below:
{
path: "student",
component: StudentComponent,
canActivate: [authenticationGuard],
data: {
role: "student",
...
1
vote
1
answer
27
views
Angular Loading time on menu click
When I click on the menu item it takes too much time to load
This is my app-routing-modules.ts
const routes: Routes = [
{
path: '',
children: [
{
path: 'login',
...
0
votes
0
answers
24
views
Angular apps loaded from aspx page adds extra slash and doubles URL on server
I'm encountering an issue where an Angular 16 app, loaded in ASPX page (default.aspx), is adding an extra slash on the dev machine and on server, it is doubling the URL.
I have added base url in the ...
0
votes
1
answer
34
views
NG8001: 'app-servers' is not a known element
Error
Code
I have tried everything but failed to resolve
I am using same selector but not resolved
It should display label, input box and button.
I have tried the solutions given but not resolved my ...
2
votes
1
answer
56
views
Im using the latest AuthGuard method, its supposed to redirect using router.createUrlTree if user is not logged in but it fails to do so
Im unable to redirect to /user pleas help
here is the AuthGuard where I have subscribed to an authService.authSubStatus that emits a boolean
import { inject, Injectable } from '@angular/core';
import {...
0
votes
0
answers
16
views
ui-router transition params contains the hash-bang
I'm updating my web application to a newer version of angularJs (from 1.5 to 1.8) and ui-router (from 0.2 to the latest available).
After those updates, $stateParams, which I use to handle query ...
0
votes
0
answers
41
views
Angular (17): extra margin problem when navigating from a page to another
I'm working on an Angular project where I have both login and sign-up pages. They share the following CSS:
html, body {
width: 100%;
height: 100%;
margin: 0;
padding: 0;
overflow-y:...
-1
votes
1
answer
15
views
Angular changes URL, but doesn't open child
I'm getting strange behaviour.
My parent URL has this.
ProjectsComponent HTML snippet
<a [routerLink]="[contract._id]">{{ contract.name }}</a>
Scenario 1
When I navigate to the ...
0
votes
3
answers
104
views
When I navigate to the URL'http://localhost:4200/', it redirects me back
login.components.ts:
import {Component, OnInit} from '@angular/core';
import {FormBuilder, FormGroup, ReactiveFormsModule, Validators} from "@angular/forms";
import {AuthService} from &...