I'm updating the markdown parser and want to be sure I'm handling all new types of links e.g. links to communities or users.
If you can please comment any examples I'll add support.
Cheers, Lj!
edit: testing a link
edit 2: https://lemmy.world/post/1986302
edit 3: https://feddit.uk/post/699250
edit 4: https://lemmy.ml/post/2335045
edit 5: https://lemmy.world/comment/1706265
edit 6: https://lemmy.ml/comment/1651859
edit 7: https://lemmy.ml/c/asklemmy
edit 8: https://kerala.party/c/asklemmy@lemmy.ml
edit 9: https://lemmy.ml/u/ljdawson
edit 8: https://kerala.party/u/ljdawson@lemmy.world
edit 9: https://latte.isnot.coffee/post/6799
edit 10: !android@lemmy.world
edit: 11: @ljdawson@lemmy.ml
90 Comments
Zeus@lemm.ee · 32 pts · 3y
lemmy also (unofficially) supports footnotes.[^1] you may want to view this in a browser^[as it currently doesn't render in any mobile clients]^[also note the differing positions of the caret]
additionally, with no markdown linking at all, the web interface^[and i believe most apps] automatically turns
!community@instance.tldinto a link: !community@instance.tld[^1]: with two different syntaxes
Historical_General@lemmy.world · 1 pts · 3y
That's interesting. ^[Markdown is very cool]
thurstylark@lemm.ee · 30 pts · 3y
Shrug emote in backticks:
¯\_(ツ)_/¯Shrug emote unescaped: ¯_(ツ)_/¯
Shrug emote properly escaped: ¯\_(ツ)_/¯
luffyuk@lemmy.world · 13 pts · 3y
This is the real shit right here.
Nugget@lemmy.world · 29 pts · 3y
Italic Italic
Bold Bold
Deferred Link
Horizontal Rule
hello world
Horizontal Rule
hello world
Inline codewith backticks::: spoiler secrets hi :::
Some
subscripttextSome ^superscript^ text
eco_game@discuss.tchncs.de · 15 pts · 3y
subscript and superscript don't work for me on Jerboa
maltasoron@sopuli.xyz · 12 pts · 3y
Same on Thunder. Also, the spoiler isn't hidden.
thurstylark@lemm.ee · 6 pts · 3y
Same on Connect
jvrava9@lemmy.ml · 3 pts · 3y
med@sh.itjust.works · 1 pts · 3y
Nor in liftoff 10.9 on iOS
chemsed@lemmy.ca · 1 pts · 3y
I'm on the beta version and here are the issues that I notice. The first horizontal line make the text bold instead of making a line. I think that you cannot "close" a subscript or a superscript. I find the copy block button a bit too large. I think that you used the wrong spoiler tag.
Here below my test on the beta version:
~x = x^2
Any way, I give my energy to the sync developer and testers ༼ つ ◕_◕ ༽つ
I am not yet subscribed in the Canada community in lemmy.ca, but I should
not.OvermindDL1@programming.dev · 1 pts · 2y
Testing some code syntax highlighting (may or may not work depending on UI being used):
Nested (more backticks on our fence nest lesser backticks inside):
A10@kerala.party · 23 pts · 3y
https://kerala.party/c/asklemmy@lemmy.ml
https://lemmy.ml/c/asklemmy
SeaMauFive@lemm.ee · 14 pts · 3y
The only user in this thread who understood the assignment
thurstylark@lemm.ee · 8 pts · 3y
I mean, this isn't terribly unimportant. There definitely should be an option to view all links to lemmy communities/users through your home instance when linked like this.
Not necessarily on topic for this thread, but still...
shadearg@lemmy.world · 2 pts · 3y
/c/asklemmy@lemmy.ml
TheGreenGolem@lemm.ee · 2 pts · 3y
!asklemmy@lemmy.ml
starscar12@lemm.ee · 17 pts · 3y
Lemmy spoilers have different syntax compared to reddit:
::: spoiler This is a spoiler hiding some text
We're no strangers to love
You know the rules and so do I (do I)
A full commitment's what I'm thinking of
You wouldn't get this from any other guy
I just wanna tell you how I'm feeling
Gotta make you understand
Never gonna give you up
Never gonna let you down
Never gonna run around and desert you
Never gonna make you cry
Never gonna say goodbye
Never gonna tell a lie and hurt you
:::
omey@lemmy.world · 19 pts · 3y
For some reason, spoiler tags don't work on my end. I use Connect.
maltasoron@sopuli.xyz · 9 pts · 3y
Same on Thunder.
Mr_Blott@lemmy.world · 10 pts · 3y
Same on Liftoff
burgersc12@sh.itjust.works · 9 pts · 3y
portside@monyet.cc · 3 pts · 3y
None of these work in liftoff
can@sh.itjust.works · 6 pts · 3y
Working well on Summit!
NicoCharrua@lemmy.ca · 5 pts · 3y
Works on Jerboa too
superminerJG@lemmy.world · 3 pts · 3y
@VonReposti
VonReposti@feddit.dk · 15 pts · 3y
codeby using ` (this is escaped)Example link
Bold
Italic
Heading 1
Heading 2
Heading 3
Heading 4
StrikethroughDerpyPlayz18@lemm.ee · 12 pts · 3y

Example:
aquinteros@lemmy.world · 1 pts · 3y
it works in thunder just fine
Annoyed_Crabby@lemmy.world · 10 pts · 3y
The image markdown also support mp4 as well
A10@kerala.party · 9 pts · 3y
Link to custom Emoji
anonymoose@lemmy.ca · 6 pts · 3y
Wow, this rendered as a gif on my client (Connect). Did you just write it as an emoji?
That makes me realize that a "view raw" or "view code" button would be awesome.
burgersc12@sh.itjust.works · 6 pts · 3y
anonymoose@lemmy.ca · 4 pts · 3y
Yeah, I knew about that, but I didn't know custom emojis were global. Cool feature!
A10@kerala.party · 4 pts · 3y
I type : and then the custom emoji name, Lemmy Website Auto completes the markdown for it.
anonymoose@lemmy.ca · 4 pts · 3y
Cool!
joshLaserbeam@sh.itjust.works · 8 pts · 3y
Link to a post with a table inside a spoiler
And another good test
veganpizza69@lemmy.world · 8 pts · 3y
I'm not going to post here, but try these: https://book.hacktricks.xyz/pentesting-web/xss-cross-site-scripting/xss-in-markdown
Xylight@lemmy.xylight.dev · 8 pts · 3y
Communities:
Users:
Undearius@lemmy.ca · 1 pts · 3y
This syntax automatically converted to a link on the web that will open on a users home instance:
will link to (myinstance.com/c/community@domain.tld)will link to (myinstance.com/c/community@example.com)syntax used by kbin (for magazines). Will link to (myinstance.com/c/community@domain.tld)will link to user (myinstance.com/c/community@domain.tld)This syntax does NOT convert to a link:
ljdawson@lemmy.world MOD · 8 pts · 3y
Razp@lemm.ee · 3 pts · 3y
It works.
TheBig2023Meltdown@lemmy.world · 7 pts · 3y
@TestingBot_123@lemmy.world
mruczek@lemmy.world · 7 pts · 3y
A10@kerala.party · 6 pts · 3y
!syncforlemmy@lemmy.world
ShittyKopper@lemmy.blahaj.zone · 5 pts · 3y
Something I haven't seen most apps do (but the webui does) is converting
(tm)=> (tm)no clue if there are similar substitutions out there, would probably need to check the code to confirm
ljdawson@lemmy.ml · 4 pts · 3y
This is a test
ljdawson@lemmy.world · 2 pts · 3y
Reply from messaging tab
galim@lemmy.ca · 2 pts · 3y
Hi
ljdawson@lemmy.world · 2 pts · 3y
Howdy
sabreW4K3@lemmy.tf · 2 pts · 3y
nice! Can you see this?
ljdawson@lemmy.world · 3 pts · 3y
Yup!
phuntis@sopuli.xyz · 2 pts · 3y
test
ljdawson@lemmy.world · 2 pts · 3y
Testing
sabreW4K3@lemmy.tf · 2 pts · 3y
Relying with markdown to
stayon#topic
ljdawson@lemmy.world · 2 pts · 3y
Boo
Xylight@lemmy.xylight.dev · 2 pts · 3y
AAAA!!! 😱😱😱😨😨😨😨
ljdawson@lemmy.world · 1 pts · 3y
ljdawson@lemmy.world · 1 pts · 3y
can@sh.itjust.works · 4 pts · 3y
#i take it back third image in link is NSFW when I copied the code for some reason! It's just rick roll on the actual link though? Sorry, this formatting is still new to me.
Testing from this post (nsfw instance, but sfw post showing markdown for multiple photos)
A10@kerala.party · 3 pts · 3y
ljdawson@lemmy.world · 2 pts · 2y
Commenting to save
lulguy@lemmy.world · 2 pts · 3y
Nested List:
lulguy@lemmy.world · 2 pts · 3y
text [^footnote] embedded.
[^footnote]: footnote text with [^another] embedded footnote with continuation
[^another]: footnote text with continuation
Random more comment after the footnotes
ljdawson@lemmy.world · 2 pts · 3y
https://feddit.uk/post/741059
phuntis@sopuli.xyz · 1 pts · 3y
ljdawson@lemmy.world · 1 pts · 3y
https://lemmy.world/post/2008060
cory_lowry@lemmy.world · 1 pts · 3y
phuntis@sopuli.xyz · 1 pts · 3y
@ljdawson@lemmy.world test
sabreW4K3@lemmy.tf · 1 pts · 3y
where did you post that from? It didn't parse. @ljdawson@lemmy.world
ljdawson@lemmy.world · 3 pts · 3y
Worked for me
sabreW4K3@lemmy.tf · 2 pts · 3y
It parses in app but not on the website for some reason