Replies: 2 comments 2 replies
-
|
@Art4 In the same boat… did you solve this? |
Beta Was this translation helpful? Give feedback.
-
Probably. I'm not very familiar with BBCode, so I don't know if you could properly implement everything, but parsing the type of syntax you showed would probably work.
You would use an |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Hey, I have a legacy project with user generated content written in BBCode. I would like to migrate this BBCode content to CommonMark and have started to build a BBCode extension. See here for my progress: youthweb/bbcode-parser#15
Now comes the first obstacle for creating a Delimiter for detecting
[b]text[/b]and parsing it to<strong>text</strong>. I have started looking into InlineParser and BlockPArser but my question is: Is it generally possible to detect BBCode with league/commonmark and what are the right tools for detecting simple BBCode rules?Or more specific: How can I parse
Hello [b]World[/b]!into<p>Hello <strong>World</strong>!</p>? Should I create a BlockParser or a InlineParser?Beta Was this translation helpful? Give feedback.
All reactions