LuaLS / LuaLS/lua-language-server

Hyperlink markdown still evaluated within a code block

Open
#3,435 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Lua
Stars
4.4k
Forks
442
PR merge metrics
No merged PRs in 30d

Description

How are you using the lua-language-server?

Visual Studio Code Extension (sumneko.lua)

Which OS are you using?

Windows

What is the issue affecting?

Formatting

Expected Behaviour

[]() within a continuous code block would appear as is, formatted part of the code:

--- ```
--- t[i](...)
--- ```

to appear as::

t[i](...)
Actual Behaviour

It tries to turn it into a link because it still looks for the []() pattern within a code block.

it appears as:

t[i](file:///etc...)
Reproduction steps

Write []() in a code block, indexing and a function call right next to each other.

Additional Notes

Adding a whitespace between [] and () does solve it (the code is still Lua-viable while not being recognized as a markdown link) but that is just ugly.

Log File

No response

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Reproduce the issue in the Visual Studio Code extension using a Lua code block containing t[i](...). Trace the formatting or markdown-rendering entry point responsible for code blocks; done means []() remains literal inside the block while normal links outside it still work.

Written by the indexing model from the issue text.

Assessment

Tech stack
lua
Domain
tooling
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Quiet
Clarity
Mostly clear
Newbie friendliness
58/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.