Skip to content

Always re-rendering? #240

Answered by jaredh159
bradherman asked this question in Q&A
Discussion options

You must be logged in to vote

good question. i've not had any perf issues from this myself, but it didn't seem right that two identical calls to tw would not be === so i poked around a bit and found i was spreading in one spot where i didn't need to, thus creating a new object which would trigger a rerender.

here's the PR if you're interested:

#241

i've already merged it and cut a new release: 3.6.4. would you mind testing it to see if it seems better? there are still cases where you'll fail the === test, specifically if you're also passing in a style object to be merged, but that is far rarer than just passing a string of utilities.

Replies: 2 comments

Comment options

You must be logged in to vote
0 replies
Answer selected by bradherman
Comment options

You must be logged in to vote
0 replies
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