Preserve tag name cases
quadratz opened this issue · 3 comments
Initial checklist
- I read the support docs
- I read the contributing guide
- I agree to follow the code of conduct
- I searched issues and couldn’t find anything (or linked relevant results below)
Problem
Add an option to preserve the case of HTML tags. This is similar to issue #18, but for HTML tags in general.
Currently, this
{
"type": "raw",
"value": "<TabGroup><Tab lang='js' title='JavaScript' /></TabGroup>",
}will yield
{
"type": "element",
"tagName": "tabgroup",
// ...
}Solution
TabGroup and Tab should be cased.
It should produce this output instead
{
"type": "element",
"tagName": "TabGroup",
// ...
}Welcome @quadratz! 👋
HTML is case insensitive, there are no plans to add non-html features to the HTML parser.
It looks like you may be working with XML or JSX.
If you are working with XML consider using https://github.com/syntax-tree/xast-util-from-xml
If you are working with JSX+Markdown consider using https://mdxjs.com/
Hi! This was closed. Team: If this was fixed, please add phase/solved. Otherwise, please add one of the no/* labels.
I think https://mdxjs.com/ is more suitable for my case. Thank you for the help.