3 ms·
It’s named Dockerfile. However, I suspect if it’s named jinja, the Docker parts won’t be syntax highlighted!?!?
by tecoholic 2y ago
It’s named Dockerfile. However, I suspect if it’s named jinja, the Docker parts won’t be syntax highlighted!?!?
- seabrookmx 2y agoIn my experience, yes. But you can't really expect a syntax highlighter to support every combination of template language and file language, so this seems reasonable enough.
- tecoholic 2y agoI understand the limitation. Especially in the context of having the entire syntax tree parsed and stored like Zed. I didn’t expect it to highlight 2 languages. I just wanted the Dockefile parts to be highlighted. But Zed stopped any highlighting after the first curly brace, which produces inferior results compared to the regex (assuming) based highlighters out there.
- seabrookmx 2y agoRight but the curly brace is invalid syntax in a Dockerfile. It's valid IMO for the parser to bail when it encounters this. I see what you're saying that other highlighters are continuing gracefully though.