Skip to content

BaseFormObject

Antun Badurina edited this page Jan 14, 2020 · 1 revision

Base form object is just an abstraction on top of our other form objects. All other form object will extend base form object. Base form object is optional but it is highly recommended as it simplifies the code by giving us the ability to specify data which can be accessed from all other form objects.

import { FormObject, FormObjectOptions } from 'ngx-form-object';

export class BaseFormObject extends FormObject {
  constructor(
    public model: any,
    protected options: FormObjectOptions
  ) {
    super(model, options);
  }
}
Clone this wiki locally