bug: Tables don't render correctly if the pipe at the end of line is missing
Valutazione
- Difficoltà
- 3/5
- Tempo stimato
- 1-2 giorni
- Idoneità per principianti
- 55/100
Direzione di ricerca
Riproduci il problema in Neovim usando la tabella Markdown mostrata nel report e la configurazione pipe_table fornita, quindi traccia il modo in cui il plugin riconosce le tabelle senza una pipe finale. Il lavoro è completato quando l’esempio viene renderizzato correttamente preservando il comportamento esistente delle tabelle; aggiungi o esegui un test di regressione mirato se il progetto ne dispone.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Descrizione
Neovim version (nvim -v)
0.12.2
Neovim distribution
LazyVIM
Operating system
Linux (Arch, btw)
Terminal emulator / GUI
Alacritty
Describe the bug
Tables are not rendered correctly if the trailing pipe is omitted.
From GitHub-flawored markdown spec (common mark doesn't have tables):
A leading and trailing pipe is also recommended for clarity of reading, and if there’s otherwise parsing ambiguity.
Recommended - not required.
I usually omit the trailing pipes - the tables look ok in plain text without inserting dozens of empty spaces to align the right border.
Table like this should be valid and render correctly.
It looks good in plain text, without a need to insert dozens of spaces
| state | dscription
|--------|---
| open | port is accessible, and service is listening
| closed | port is accessible, but no service is listening
Expected behavior
Tables without a trailing pipe should be rendered correctly.
Healthcheck output
==============================================================================
render-markdown: 3 ⚠️
render-markdown.nvim [versions] ~
- ✅ OK neovim >= 0.11
- ✅ OK tree-sitter ABI: 15
- ✅ OK plugin: 8.13.0
render-markdown.nvim [configuration] ~
- ✅ OK valid
render-markdown.nvim [tree-sitter markdown] ~
- ✅ OK parser: installed
- ✅ OK ABI: 15
- ✅ OK highlights: ~/.local/share/nvim/site/queries/markdown/highlights.scm
- ✅ OK highlighter: enabled
render-markdown.nvim [tree-sitter markdown_inline] ~
- ✅ OK parser: installed
- ✅ OK ABI: 15
- ✅ OK highlights: ~/.local/share/nvim/site/queries/markdown_inline/highlights.scm
render-markdown.nvim [tree-sitter html] ~
- ✅ OK parser: installed
- ✅ OK ABI: 14
render-markdown.nvim [tree-sitter latex] ~
- ⚠️ WARNING parser: not installed
- ADVICE:
- disable latex support to avoid this warning
require("render-markdown").setup({
latex = { enabled = false },
})
- ⚠️ WARNING ABI: unknown
- ADVICE:
- disable latex support to avoid this warning
require("render-markdown").setup({
latex = { enabled = false },
})
render-markdown.nvim [tree-sitter yaml] ~
- ✅ OK parser: installed
- ✅ OK ABI: 15
render-markdown.nvim [icons] ~
- ✅ OK using: mini.icons
render-markdown.nvim [latex] ~
- ⚠️ WARNING none installed: { "utftex", "latex2text" }
- ADVICE:
- disable latex support to avoid this warning
require("render-markdown").setup({
latex = { enabled = false },
})
render-markdown.nvim [conflicts] ~
- ✅ OK headlines: not installed
- ✅ OK markview: not installed
- ✅ OK obsidian: not installed
Plugin configuration
config {
checkbox = {
bullet = true,
checked = {
icon = ""
},
custom = {
todo = {
rendered = ""
}
},
unchecked = {
icon = ""
}
},
code = {
border = "thin",
right_pad = 1,
width = "block"
},
file_types = {
[2] = "norg",
[3] = "rmd",
[4] = "org",
[5] = "codecompanion"
},
heading = {
icons = { vim.NIL, vim.NIL, vim.NIL, vim.NIL, vim.NIL, vim.NIL }
},
pipe_table = {
border_enabled = false
}
Plugin error log
N/A
Confirmations
- I have updated this plugin to the latest version using my plugin manager
- I have updated all treesitter parsers (:TSUpdate)
- I have provided the text contained in all screenshots as raw text in this issue. This means if there is a screenshot below it is the copy pasted contents of the file in the screenshot. I understand that my issue will be closed if I have not.
Additional information
No response
- Lingua principale
- Lua
- Stelle
- 5.1k
- Fork
- 144
- Metriche di merge delle PR
- Nessuna PR unita negli ultimi 30g
Preparare l'ambiente
Questo progetto non fornisce container di sviluppo, Dockerfile né guida per i contributori, quindi l'ambiente è a tuo carico: parti dal suo README e consulta la nostra guida al primo contributo per i passaggi generali.
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Altre issue di MeanderingProgrammer/render-markdown.nvim
-
enhancement
Difficoltà 5/5 Più di una settimana Idoneità per principianti 38/100
-
enhancement
Difficoltà 4/5 3-5 giorni Idoneità per principianti 48/100
Tutte le issue di MeanderingProgrammer/render-markdown.nvim
Issue simili
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 70/100
I maintainer di solito rispondono entro 3 giorni
-
Campaign WC
Difficoltà 2/5 1-3 ore Idoneità per principianti 60/100
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 74/100
public-transport/transitous#2569 · 1 commento ·
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 1/5 Meno di un'ora Idoneità per principianti 82/100
-
core: a monitored method's raise rewrites every ? of its message, a resumed runtime's text includedApertaseverity: low
Difficoltà 2/5 1-3 ore Idoneità per principianti 78/100
luainkernel/lunatik#1861 ·
I maintainer di solito rispondono entro 1 giorno