This way we don't need to create and loop through every component. (cherry picked from commit 47b586bf)