Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Syntax highlighting in json files #109

Open
benjaminbosko opened this issue Sep 30, 2022 · 2 comments
Open

Syntax highlighting in json files #109

benjaminbosko opened this issue Sep 30, 2022 · 2 comments
Labels

Comments

@benjaminbosko
Copy link

In case of quoted strings the syntax highlighting is not working in json files.
image

Originally posted by @benjaminbosko in #84 (comment)

@panoply
Copy link
Owner

panoply commented Oct 7, 2022

Hey @benjaminbosko

I have not forgotten about this but am a little hesitant on making it available anytime soon. The reason for this is because Yaml and JSON files apply Liquid syntax support using injection grammars. This might be a little problematic for folks who have installed the extension but are not always working with Liquid.

Take the following code sample:

{
  "property": "{%"
}

The above sample will invalidate scopes proceeding the unclosed Liquid delimiter. This is actually the case with Yaml presently and though I shipped it in v3.0.0 it is indeed problematic. I need to look into improving this aspect and potentially re-thinking how I currently employ the grammar scopes as I'd preferably like to avoid edge cases of this nature no matter how rare.

I'll keep this open and investigate this more. It is not impossible, I just need to work out the best way to implement it.

@benjaminbosko
Copy link
Author

Sure. Thank you in advance!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants