How do you use string interpolation Angular 4?
String interpolation in Angular is a one-way data-binding technique used to take the output data from a typescript code and into an HTML template. It uses the template expression through double curly braces {{ }} displaying the data from a component to view.
Here’s an example to show you how to use String Interpolation:
import {Component} from ‘@angular/core’;
@Component({
selector: ‘app-root’,
templateUrl:’./app.component.html’,
styleUrls: [‘./app.component.css’]
})
export class AppComponent {
title=’string interpolation in tutorialandexample’;
}
BY Best Interview Question ON 12 Jun 2020