Topics Various subjects that interest me
Query monitor twig profile WordPress performance plugin
To show performance information about your page load, Query Monitor Twig Profile (QMTP) needs to know what Twig is doing. For this you will have to supply a reference to the Twig Environment.
If you use Timber or Clarkson Core this happens automatically. Otherwise you need to complete the integration manually.
You can manually integrate QMTP into your project.
filter
or action
. Consult the documentation of your framework to find out more.Twig Environment
object to QMTP.functions.php
file in your theme.if ( function_exists( 'NdB\QM_Twig_Profile\collect' ) ) {
$twig = \NdB\QM_Twig_Profile\collect( $twig );
}
After adding the correct code snippet, QMTP will show you the profile of your page in the Query Monitor admin bar tab.
You can experiment for yourself, or read more about interpreting the results.