-1

I have following html string that i can fetch from http service:

When uranium was {{1}} to be radioactive, Marie Curie found that the element called {{2}} had the same property.

I want to replace {{1}} and {{2}} with reactive form control in angular 5 dynamically. how?

2 Answers 2

0

It isn't possible to generate reactive form inputs dynamically as they should be rendered by Angular.

But you can have this inputs in html prepared but hidden. Then set text in appropriate places and make visible.

Sign up to request clarification or add additional context in comments.

Comments

0

Angular Dynamic Compile component, that turns a string into a compiled component

dynamic template to compile dynamic Component

Comments

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.