P
P
Pogran2017-01-31 16:24:48
Angular
Pogran, 2017-01-31 16:24:48

Why are the styles not working?

I have Angular 2. I am using composite routing.

//router
   {
        path: 'login',
        component: LoginLayoutComponent,
        children: [
            {
                path: '',
                component: LoginComponent
            }
        ],
    },

// layout component
import {Component} from "@angular/core";
@Component({
    moduleId: module.id,
    selector: 'login-layout',
    templateUrl: 'login-layout.component.html',
    styleUrls: ['/assets/css/login.css']
})

export class LoginLayoutComponent {
    constructor() {}
}


// template
<router-outlet></router-outlet>

And in the debugger I see that there are no styles, what could be the matter. All paths are correct, there are no errors in the console

Answer the question

In order to leave comments, you need to log in

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question