Is there a way to escape the "hide link embed" markdown sequence?

I just checked escapeMarkdown. It allows me to escape pretty much all Discord-flavored markdown sequences, except for the "hide link embed" one. For reference: It's when you put links into angled brackets (<>), so that links in your message don't automatically embed. So: does d.js support this anywhere else? See screenshot for potential use case. This is with all EscapeMarkdownOptions already set to true.
No description
9 Replies
d.js toolkit
d.js toolkit15mo ago
- What's your exact discord.js npm list discord.js and node node -v version? - Not a discord.js issue? Check out #other-js-ts. - Consider reading #how-to-get-help to improve your question! - Explain what exactly your issue is. - Post the full error stack trace, not just the top part! - Show your code! - Issue solved? Press the button!
NKN1396
NKN1396OP15mo ago
- discord.js 14.13.0 - node 18.17.1
Unknown User
Unknown User15mo ago
Message Not Public
Sign In & Join Server To View
NKN1396
NKN1396OP15mo ago
Alright, thanks for the answer. Looks like this might need a fix, so I'll open an issue on GH.
Unknown User
Unknown User15mo ago
Message Not Public
Sign In & Join Server To View
NKN1396
NKN1396OP15mo ago
No, I'm saying that formatters has no way to escape hidden link embeds. E.g. when I pass the string <f://g.d> to the escapedMarkdown() function, I'd like to get \<<f://g.d>>. My specific use case is for when users change their name to something like <https://www.google.com/> (with angled brackets), see image on original post. The bot would display that new username. Ideally, it should look like <https://www.google.com/>, rather than just https://www.google.com/ like it does in aforementioned image.
Unknown User
Unknown User15mo ago
Message Not Public
Sign In & Join Server To View
NKN1396
NKN1396OP15mo ago
It's not just about escape hidden link embeds. I'd like to escape everything that's possible. Codeblocks can't handle backticks as far as I'm aware. A more extreme example (no way for me to even display this correctly inline):
~~***__<f://g.d>__***~~||`M`||\\
~~***__<f://g.d>__***~~||`M`||\\
- Un-escaped, this renders as <f://g.d>M\ - Ideally, it should render as ~~***__<<f://g.d>>__***~~||`M`||\\ (Identical to the text in the code block) - Letting d.js handle it, it renders as ~~***__<f://g.d>__***~~||`M`||\\ (Note the missing angled brackets)
Unknown User
Unknown User15mo ago
Message Not Public
Sign In & Join Server To View
Want results from more Discord servers?
Add your server