How to add the image url in the head tag Do youknow how to add the image url to the head tag?

This is what I've tried so far

Example

&lt;head&gt;
     &lt;meta property="og:image" content="  {{ file_create_url(node.field_image.0.entity.uri.value) }}        "/&gt;
     &lt;meta property="og:image:secure_url" content="  {{  file_create_url(node.field_image.0.entity.uri.value)  }} " /&gt;
&lt;/head&gt;


Thanks!
Or possibly a better solution - use the metatag module and you can customise this through the CMS globally or for specific pages. "og" stands for Open Graph so you just need to pop your data in the relevant open graph section

https://www.drupal.org/project/metatag