https://kotlinlang.org logo
#announcements
Title
# announcements
z

zkeme

09/27/2019, 5:13 PM
Hi guys! Is there any way to use triple backticks in KDoc and still have links inside?
r

Ruckus

09/27/2019, 5:23 PM
Why would you want this? Generally (as far as I'm aware) you want your code samples to be copy-paste able by users. Adding links seems counterproductive.
z

zkeme

09/27/2019, 5:29 PM
image.png
I want to do something like that in the docs of that interface.
If I don't use ``` then the formatting is not kept. If I use it, then the link is lost.
Sorry If I wasn't clear before 🙂
r

Ruckus

09/27/2019, 5:31 PM
Ah, you're not using it for code. Fair enough. It seems like a bit of a hack though. That's not really the purpose of ``` as far as I'm aware.
z

zkeme

09/27/2019, 5:32 PM
Maybe this is an IDE thing, not sure.
Here is what it is like if I don't use the ```
image.png
r

Ruckus

09/27/2019, 5:34 PM
I think it's more an issue that you're trying to use things improperly. You should probably just use
<table>
tags.
z

zkeme

09/27/2019, 5:35 PM
doest that exist for KDoc? 😛
r

Ruckus

09/27/2019, 5:35 PM
KDoc uses markdown, so you should be able to use any HTML tags in there (again, unless I'm mistaken)
I haven't tried yet though
r

Ruckus

09/27/2019, 5:37 PM
The table shorthand syntax in that question is non-standard (I believe it's part of the GitHub markdown extensions). You should be able to use the HTML tags just fine.
z

zkeme

09/27/2019, 5:40 PM
This doesn't work on call site either 😞
image.png
image.png
nothing about the table is shown
oh well, its not like its a big deal 😛 I'll just lose the links
r

Ruckus

09/27/2019, 5:44 PM
Dang. I wonder why. Well, I guess you can vote for the issue https://youtrack.jetbrains.com/issue/KT-16228
I guess you're right. It does appear to be an IDE issue. The shorthand does get rendered properly by Dokka, just not in IDEA.
z

zkeme

09/27/2019, 6:13 PM
Yap.. oh well
Just in case someone is reading this, in my case I can just use bullet points with
-
Since I don't really need a table, this is good enough for me
25 Views