0

I have a form with 2 fields, 1 of it is an array. I would like to make this whole form as a array, when i click Add question, it will dynamically have another 2 fields like this.

Add Question 1 - All fields are mandatory (Add question) Ask your question *
Answer 1 *

Add Question 2 - All fields are mandatory Ask your question *
Answer 1 *

Another Answer

I've tried but failed. Please kindly help. Thank you. below is the code in StackBlitz.

StackBlitz: https://stackblitz.com/edit/angular-j92gcm?file=app%2Fapp.component.css

7
  • I've tried but failed Please elaborate what is the error are you getting? Commented Jan 22, 2018 at 7:31
  • 1
    plnkr.co/edit/clTbNP7MHBbBbrUp20vr?p=preview this should be helpful :) Commented Jan 22, 2018 at 7:36
  • See also stackoverflow.com/questions/42783400/… Commented Jan 22, 2018 at 7:39
  • @AbhishekEkaanth thanks i will try it. Any idea how does the app.component uses the contract.component? I don't see any routing or import. Commented Jan 22, 2018 at 9:16
  • I did not understand. what you are trying to convey. Commented Jan 22, 2018 at 9:20

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.