-
Notifications
You must be signed in to change notification settings - Fork 54
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
🐞 Bug: Code blocks language parsing from info string only works for 3 backticks without spaces #234
Comments
Oh, you already provided a fix on I just tested |
Which part of it is broken? |
At first, It seems to conflict with
When I deactivate Snack I have this error:
|
Which colorscheme are you using? |
Solarized Osaka with those settings: --- Solarized Osaka
--- https://github.com/craftzdog/solarized-osaka.nvim
{
"craftzdog/solarized-osaka.nvim",
lazy = false,
priority = 1000,
config = function()
require("solarized-osaka").setup({
transparent = true, -- Disable setting background
dim_inactive = true, -- Non focused panes set to alternative background
styles = {
sidebars = "transparent",
},
})
vim.cmd("colorscheme solarized-osaka")
end,
}, |
I think you are loading |
Yes, Snack is one of the first loaded plugin (on purpose) due to some early dependencies I have on it (including debugging facilities). |
What happens if you add |
Still the same issue even as a dependency. |
That's strange. Unless What's your |
I have tested with So, it's most likely something else in your config. |
Before reporting:
Problem:
Language parsing from code block info string is broken when not exactly 3 backticks followed by language without space.
According to CommonMark specs (so this also includes, GFM, GLFM, Myst and Obsidian which are all based on CommonMark):
Steps to reproduce the issue:
Just try the following markdown snippet
Sample markdown
Github rendering
Tilde fence
spaces after fence
More than 3 backticks
Markview rendering
As you can see:
Expected behavior:
In all 3 cases, language is properly parsed from the info string (starts after the fence, whatever its size, leading spaces ignored and works with tilde fence).
Bonus if it works with Markdown-It custom containers, Markdown-It-Py containers and Myst directives colon fence
Neovim version:
0.10.3
The text was updated successfully, but these errors were encountered: