One way binding in angular is used set or get the data from html controls, here lets see how to get the value from Textbox on button click and show the same in some span.
import { Component} from '@angular/core';
@Component({
selector: 'app-root',
styleUrls: ['./app.component.css'],
template: ``
})
export class AppComponent {
userEneteredText :string;
showData(value :string){
this.userEneteredText=value;
}
}