get template part - get_template_part calls amount and performance?

admin2025-06-05  2

I'm trying to build the theme that is easily customizable by other developers and chose to go get_template_part route so files can be easily overwritten in child theme.

My question is there some kind of limit for get_template_part until it hurts performance?

For example, I'm using it for building a card UI, so each card has 5-10 get_template_part calls. If page displays 40 cards, that would be 400 disk lookups — could it hurt the performance? Is it better to move to regular functions (e.g. template tags)?

转载请注明原文地址:http://conceptsofalgorithm.com/Algorithm/1749108911a316435.html

最新回复(0)