Schema forms for Ionic v2 and up using the angular2-schema-form module.
npm install ionic-schema-form --save
Import the ionic-schema-form module:
import { NgModule } from '@angular/core';
import { IonicApp, IonicErrorHandler, IonicModule } from 'ionic-angular';
import { SchemaFormModule, WidgetRegistry } from "angular2-schema-form";
import { IonWidgetRegistry, IonSchemaFormModule } from "ionic-schema-form";
import { MyApp } from './app.component';
import { HomePage } from '../pages/home/home';
@NgModule({
declarations: [
MyApp,
HomePage
],
imports: [
IonicModule.forRoot(MyApp),
SchemaFormModule,
IonSchemaFormModule
],
bootstrap: [IonicApp],
entryComponents: [
MyApp
],
providers: [
{provide: WidgetRegistry, useClass: IonWidgetRegistry}
]
})
export class AppModule {}