browser-compat-data
browser-compat-data copied to clipboard
Allow use of Markdown in description and notes
This PR updates the build/lint scripts to allow the use of Markdown for descriptions and notes internally. To retain compatibility with consumers, the Markdown is then converted to HTML.
This is a purely internal change that will not impact consumers, let alone warrant a semantic versioning bump. This will only positively impact maintainers.
Note: some of our notes already have Markdown formatting.
Follow-Up Work
After this PR is approved, we should go through and convert all of our notes to Markdown format in a bulk update.
FUTURE Schema Change Proposal
I plan to open an issue to formally propose this, however I am unsure if we want to do this change now while converting to Markdown, so I am mentioning it here.
To allow consumers to utilize the Markdown versions if they wish to, I am proposing a future change to the schema to convert the notes
property into an object containing both formats, like so:
{
notes: {
md: "**Foo** bar",
html: "<strong>Foo</strong> bar"
}
}
Alternatively (though I'm less favorable of this), to keep from making a breaking change, we can add a notesMD
property alongside the HTML version:
{
notes: "<strong>Foo</strong> bar",
notesMD: "**Foo** bar"
}
I'm all for it, though I think this needs a decision from the maintainers.
A question: does this lead to a new major release?
Maybe we should do it in two phases: changing the schema, allowing some time for consumers (MDN displays these notes, maybe others) to adapt, and then making the textual changes (If I remember well, HTML tags are valid in MD, so it should be ok).
A question: does this lead to a new major release?
No, this actually does not change the schema! To the end user, they'll just see a few notes change, but they're still formatted as HTML.
My apologies, I didn't clarify that the schema proposal is for a future schema change. This PR purely changes internal formatting for maintainers. I updated the PR description to clarify this.
This pull request has merge conflicts that must be resolved before it can be merged.
This pull request has merge conflicts that must be resolved before it can be merged.
This pull request has merge conflicts that must be resolved before it can be merged.
This pull request has merge conflicts that must be resolved before it can be merged.
This pull request has merge conflicts that must be resolved before it can be merged.
This pull request has merge conflicts that must be resolved before it can be merged.
This pull request has merge conflicts that must be resolved before it can be merged.
When's this planned? Very much looking forward to working in markdown.
This pull request has merge conflicts that must be resolved before it can be merged.
This pull request has merge conflicts that must be resolved before it can be merged.
This pull request has merge conflicts that must be resolved before it can be merged.
This pull request has merge conflicts that must be resolved before it can be merged.
This pull request has merge conflicts that must be resolved before it can be merged.