I am running my front-end application using the Angular-Cli.
I want to add a css file from the node_module
only to that specific component. I do not want to add the CSS file to the Angular.cli.json "scripts": []
array,
I have the following component:
import {Component, OnInit} from '@angular/core'; @Component({ selector: 'fbsign-component', templateUrl: './fb.signin.component.html', styleUrls: ['./fb.signin.component.css', '../../node_modules/bootstrap-social/bootstrap-social.css'] }) export class FbSigninComponent{ constructor(){} ngOnInit(): any{} onClick(){ window.location.href ="http://localhost:1337/facebook" } }
I think that the something is blocking the styleURLs[]
from accessing the CSS files located in node_module
directory.
How do I unblock it?