Skip to content

[question] Add component to DOM dynamicly #2409

Answered by voidpumpkin
bigleanator asked this question in Q&A
Discussion options

You must be logged in to vote

I highly recommend you read our docs and go through our tutorial at https://yew.rs

But to give you a basic gist Yew is at its its core very dynamic / reactive (like react.js) library.
It operates on the idea that you have stored data, that you then "render" into html.

In your case you can keep the data list in yew component state and then turn them into html like shown here https://yew.rs/docs/concepts/html/lists
Then when your state changes your component will be re-rendered based on the new list :)

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by bigleanator
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants
Converted from issue

This discussion was converted from issue #2406 on January 25, 2022 07:23.