The summary provided on this.$site.pages can contain a broken markdown.
We are facing this issue on https://theheadless.dev when the summary is trimmed based on the configured characters there could be scenarios where the markdow is not valid anymore (please check the image attached).
In our case, we are setting a max length of 120 characters (summaryLength config), and the text of the image above is:
The [HyperText Transfer Protocol (HTTP)](https://developer.mozilla.org/en-US/docs/Web/HTTP#:~:text=Hypertext%20Transfer%20Protocol%20(HTTP)%20is,be%20used%20for%20other%20purposes.) is stateless, but cookies allow it to keep context consistent over the course of a session. In other words, by having our browser automatically exchange small amounts of data, we get to have websites recognise us and remember our preferences, the contents of our shopping baskets or the fact that we had just logged in to our account.
BTW this is a public repo, so feel free to check the configuration here https://github.com/checkly/theheadless.dev
Option A) before trimming, remove the markdown from the summary
Option B) trim the text without counting markdown characters, so it ensures that is always valid.
As attached below, the markdown is invalid so it looks weird.

Hello @maxigimenez !
This seems to look like an API you guys have augmented your theme with here: https://github.com/checkly/theheadless.dev/blob/master/blog/.vuepress/theme/index.js#L6
I suspect the issue here might be with remove-markdown, but since I personally haven't implemented this, this is just an educated guess

Have confirmed, is an issue with remove-markdown
Thank you @d-pollard! Wasn't aware of that file in our configuration.
No problem! Am interested in how you guys fix it, feel free to update and tag me here @maxigimenez
@d-pollard We fix our logic to trim the summary https://github.com/checkly/theheadless.dev/pull/84 to be done after the remove-markdown is trigger.
Also we escape the () for %28/29 on the example above to prevent issues with remove-markdown.