ui5-webcomponents
ui5-webcomponents copied to clipboard
Reactive Forms Angular
Hello everyone
- I implement the use of reactive forms with the ui5-input control but it still doesn't work

Visit Issue # 697 but it doesn't work
Still have no support for this?
Do I need to implement any module?
Thanks for the help
Hi @camilo2312
In order to use UI5 Web Components with Angular two way data binding you have to provide ControlValueAccessor for the used components. In our Angular tutorial you can check out Two-way data binding section.
In order to make it work:
- Install Origami:
npm install @codebakery/origami
- Import the OrigamiFormsModule from Origami
import { NgModule, CUSTOM_ELEMENTS_SCHEMA } from '@angular/core';
import { BrowserModule } from '@angular/platform-browser';
import { OrigamiFormsModule } from '@codebakery/origami/forms';
import { AppComponent } from './app.component';
@NgModule({
imports: [BrowserModule, OrigamiFormsModule],
declarations: [AppComponent],
schemas: [CUSTOM_ELEMENTS_SCHEMA],
bootstrap: [AppComponent]
})
export class AppModule {}
- Use it in your template
<ui5-input [(ngModel)]="value" origami></ui5-input>