Hemant Kumar

Hemant Kumar

  • NA
  • 3
  • 453

adding image path

Sep 13 2018 1:55 AM
Hello, I want to set a universal image path for my project. how I do that please suggest. now I am giving image path like this, but this is working only for a particular component. I cant use this image for another component, I thank it's not a proper way.
 
import { Component, OnInit } from '@angular/core';
@Component({
selector: 'app-services',
templateUrl: './services.component.html',
styleUrls: ['./services.component.css']
})
export class ServicesComponent implements OnInit {
imageUrl = 'https://hemant07.github.io/project-images/images/';
constructor() { }
ngOnInit() {
}
}

Answers (1)