Skip to content

heavy calculations inside sycamore::render closure #514

Answered by lukechu10
ghost asked this question in Q&A
Discussion options

You must be logged in to vote

sycamore::render only runs once. It essentially works exactly the same as a component. I don't understand why you would want the closure to run multiple times. Usually, you should try to put all your logic in your App component to keep fn main as simple as possible.

If you have reactive data, you could use create_memo or create_selector etc...

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
1 participant