Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
// dynamic-form-control.component.ts
import { DynamicControlConfig } from './../dynamic-control.config';
import { FormGroup } from '@angular/forms';
import { Component } from '@angular/core';
// tslint:disable-next-line:component-selector
selector: 'dynamic-form-control',
template: `
<div [formGroup]="formGroup" class="form-group">
<input [type]="controlConfig.type" class="form-control"
[placeholder]="controlConfig.placeholder" [formControlName]="">
export class DynamicFormControlComponent {
formGroup: FormGroup;
controlConfig: DynamicControlConfig;
constructor() { }
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.