Open takrishna opened 1 week ago
Thanks for the excellent reproduction
I added a fork of it with a fix: https://stackblitz.com/~/github.com/takrishna/lion-demo/tree/takrishna/interleave-field-in-a-form?file=lion-demo.js
The solution is a keyed repeat directive. Would you be willing to contribute some docs on Lion for this?
Expected behavior
lion form to allow new fields to be inserted in between fields (interleaved) in a form that has already been rendered (say, upon re-render).
Actual Behavior
lion form assumes that no new fields can be inserted/interleaved in a form and throws an exception. However when the new field is inserted in the end it works as expected without any errors.
Reproduced here: URL: https://stackblitz.com/~/github.com/takrishna/lion-demo/tree/takrishna/interleave-field-in-a-form?file=lion-demo.js:L26
Branch: takrishna/interleave-field-in-a-form
Additional context
I am trying to solve a requirement where the user answers the first question and depending upon the answer of the first question we display some additional questions.