-
Notifications
You must be signed in to change notification settings - Fork 4.7k
Closed
Labels
need feedbackAwaiting author responseAwaiting author response
Description
- I confirm that this is an issue rather than a question.
Bug report
Steps to reproduce
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
What is expected?
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.
What is actually happening?
As attached below, the markdown is invalid so it looks weird.
Other relevant information
Metadata
Metadata
Assignees
Labels
need feedbackAwaiting author responseAwaiting author response