Runtime replace pipe.
Supported version:
Angular 15
To install this library, run:
npm i ngx-replace
Import in your Angular app:
// Import ngx-replace
import {NgxReplacePipe} from "ngx-replace";
@NgModule({
declarations: [
AppComponent
],
imports: [
NgxReplacePipe,
],
bootstrap: [AppComponent]
})
export class AppModule {
}
<p>{{'My name is %name' | ngxReplace: '%name' : 'Mustafa'}}</p>