mw.wikibase.getEntity() is an expensive function which can be called several hundreds times in an article. The computing time is huge if an entity owns many properties. In most cases only a reduced properties set is used. I propose to use an additional and optional table parameter with the properties in need to reduce both computing time and memory usage.
Example:
- now: mw.wikibase.getEntity( 'Q183' )
- maybe in future mw.wikibase.getEntity( 'Q183', { 'P36', 'P37', 'P38', 'P1082', 'P1813' } )
In Wikivoyage/de articles mw.wikibase.getEntity() can be called up to 200 times per article. With an average access time of 20 ms, so it takes about 4 s computing time in total.
But there are application in other projects like Wikicite-Wikidata calls, too.