2

I have different buttons on template like input, checkbox, radio, button etc and on the click of each button their corresponding form field should get displayed.

eg - on click of input button, input button component should be created dynamically and should get displayed. And this fields also have remove button, click of the remove button their corresponding field should be removed from the dom.

I have the basic idea about dynamically generation of component, need help to do the above scenario.

A sample object structure to render the form field can be like so:

[{
  "id": 1,
  "type": "TEXT_BOX",
  "label": "Input text box",
  "placeholder_text": "Enter your text here"
}, {
  "id": 2,
  "type": "TEXT_AREA",
  "label": "Input text area",
  "placeholder_text": "Enter your description here"
}]
Manish Balodia
  • 1,863
  • 2
  • 23
  • 37
Sonam
  • 77
  • 6

0 Answers0