LuaLS / LuaLS/lua-language-server
Additional blank lines are added to parameter descriptions in type annotations
Dieses Issue hat noch niemand übernommen.
- Vorherrschende Sprache
- Lua
- Sterne
- 4.4k
- Forks
- 442
- PR-Merge-Kennzahlen
- Keine gemergten PRs in 30 T.
Beschreibung
How are you using the lua-language-server?
NeoVim
Which OS are you using?
MacOS
What is the issue affecting?
Hover
Expected Behaviour
For multiline descriptions in @param annotations to be displayed as if they were in a single line.
Actual Behaviour
When the description in a @param annotation spans multiple lines, a linebreak in inserted in the Markdown response, which breaks syntax highlighting:
Even after removing the preceding whitespace in the example above, formatting is still off:
Reproduction steps
- Create a
luafile with the following content:
---@param bar any This is the description
--- for bar.
local function foo(bar) end
- Hover over
foo. - Notice the broken highlighting/formatting in the description of
bar.
Additional Notes
Although VS Code doesn't have additional syntax highlighting, do note how the font style in explanation above) changes, which suggests that the issue is reproducible outside Neovim:
Log File
No response
Beitragsleitfaden
Erste Schritte
- Lies das ganze Issue und danach den Beitragsleitfaden des Projekts.
- Schreib ins Issue, dass du es übernimmst — das erspart doppelte Arbeit.
- Forke das Repository und arbeite in einem Branch.
- Öffne einen Pull Request, der die Issue-Nummer nennt.
Rechercherichtung
Reproduziere das Problem anhand des bereitgestellten Lua-Beispiels, indem du in NeoVim oder VS Code mit dem Mauszeiger über foo fährst. Beginne bei der Hover-Antwort und dem Formatierungspfad für mehrzeilige @param-Beschreibungen; abgeschlossen ist die Aufgabe, wenn die Beschreibung als eine Zeile gerendert wird, ohne die Markdown-Syntaxhervorhebung in beiden gemeldeten Umgebungen zu unterbrechen.
Vom Indexierungsmodell aus dem Issue-Text verfasst.
Bewertung
- Tech-Stack
- lua
- Bereich
- tooling
- Issue-Typ
- Bug
- Schwierigkeit
- 3/5
- Geschätzter Aufwand
- 1-2 Tage
- Aktivitätsstatus
- Veraltet
- Klarheit
- Klar beschrieben
- Anfängerfreundlichkeit
- 45/100