-
Notifications
You must be signed in to change notification settings - Fork 37
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
Custom tag indentation #190
Comments
Actually only seems to do this with the 21b96afd93386499cc51004e656f2086.mp4 |
The capture tag is indentation sensitive. Changing the indentation changes the value of the string, therefore the content isn't reindented. That's because we can't change the semantic meaning of the file when reformatting. That said, it is true we don't support custom tags right now. |
Ah right, that makes sense. Is there a way to preserve indentation within the block tag? Looks a bit odd having everything within at the same level |
Not at the moment unfortunately. What's happening right now is that, because the tag isn't recognized, both the As it is, all tags that take children have to be explicitly defined in our parser. If we don't, then the parser would be ambiguous (we need to know if it can have children to push nodes as children, else we push as sibling). |
Fair enough, would be a nice feature to pass custom tag definitions somehow, but understand that's probably not as simple as it sounds. I'll leave this issue open, in case you wanna keep it, but feel free to close it now. Thanks for the explanation! |
I'm using LiquidJS which provides a custom
block
tag, this plugin doesn't indent the content within this tag correctly, treating anything inside as being on the same level.Is this intended?
Unformatted source
Expected output
Unchanged.
Actual output
Debugging information
The text was updated successfully, but these errors were encountered: