Hello!
On a project I'm working on, I want syntax highlighting for .webc components on GitHub, and so I'm using the .gitattributes workaround to get GitHub highlight appropriately.
.gitattributes
*.webc linguist-language=HTML
This works well enough, but it's something we could make work by default!
If we wanted to add this, it looks like we could open a PR to the linguist repo to add .webc as a recognized-by-default extension. We could map .webc to HTML, like the .gitattributes workaround does now.
https://github.com/github-linguist/linguist/blob/main/CONTRIBUTING.md#adding-an-extension-to-a-language
Open questions
- Can we prove that at least 200 unique
:user/:repo repositories? That's one of their requirements (I think so!)
- What are some good code examples of
.webc? They ask for some real-world examples.
- Do we have a "TextMate-compatible grammar" for webc already? If not, I wonder how hard that would be to make? That would help with highlighting in the situations where webc and html don't match perfectly (as opposed to just using HTML directly).
- In the meantime, can/should we add the
.gitattributes workaround to the documentation site? What would be a good page to add that to?
Hello!
On a project I'm working on, I want syntax highlighting for
.webccomponents on GitHub, and so I'm using the.gitattributesworkaround to get GitHub highlight appropriately..gitattributesThis works well enough, but it's something we could make work by default!
If we wanted to add this, it looks like we could open a PR to the linguist repo to add
.webcas a recognized-by-default extension. We could map.webcto HTML, like the.gitattributesworkaround does now.https://github.com/github-linguist/linguist/blob/main/CONTRIBUTING.md#adding-an-extension-to-a-language
Open questions
:user/:reporepositories? That's one of their requirements (I think so!).webc? They ask for some real-world examples..gitattributesworkaround to the documentation site? What would be a good page to add that to?