styled-components / jest-styled-components

🔧 💅 Jest utilities for Styled Components
MIT License
1.58k stars 144 forks source link

perf(utils): only extract HTML once during while loop #413

Closed me4502 closed 1 year ago

me4502 commented 1 year ago

Currently this loop calls getHTML() on each cycle, when the value doesn't or shouldn't change. This extracts it to a separate variable so it's only called once.