In Slightly, you can use the data-sly-attribute block to include dynamic values for HTML attributes, including the title and description meta tags. Here's an example of how to include the title and description meta tags in your template:
In this example, the title tag includes the dynamic title attribute using the data-sly-attribute block. The content attribute is set to the value of the metaTitle property, using the @context='html' attribute to sanitize the value. If the metaTitle property is not set, the value of the jcr:title property is used instead.
Similarly, the description meta tag includes the dynamic description attribute, with the content attribute set to the value of the metaDescription property.