wordpress bloginfo('template_directory'); parsing as a string using twig


Staff member
I'm trying to use a wordpress function which leads your path to the root of your theme in wordpress by doing:

<img src="<?php bloginfo('template_directory'); ?>/images/art.svg" alt="">

The issue is that if I inspect this I realise that the php code is parsed as a string instead of inserting a path to root of the theme. What am I doing wrong?

FYI: I'm using twig.