Luna
Administrator
Devops
Markdown
Greetings and welcome to one of the most exciting changes to the site yet: Markdown
We are replacing outdated and not very feature-rich text processing engine which we have been using so far, Textile, with something more widely used across the internet: Markdown.
Sounds cool but what does it do?
Markdown, just like Textile, is a text processing engine. It’s powering every single user interactable text that you see on the site. Everything from comments and forum posts to more obscure things like tag descriptions and report text are processed via these text processing engines.
Why the change?
Textile was getting fairly outdated and with other resources, such as Discord, Telegram, Slack, Github and many others using Markdown, it’s been an obvious choice for us. With most of the internet already using Markdown to format its content, most people would be familiar with it to some degree. This familiarity, safety, user-friendliness and the fact that it has less bugs that our Textile parser, were the driving force behind this change.
What flavor of Markdown does Furbooru use?
We’re using Github-Flavored Markdown with our own modifications to support syntax commonly used on our site. Of notable things that we have implemented into our version of CommonMark we should note the following:
- Subscript
- Spoilers
- Strikethrough
- Underline
- >>image syntax
- Blockquotes that don’t require lots of empty lines and require a space after them
How is it implemented?
We have forked and modified comrak to achieve our features. The Elixir code of the site compiles and plugs the Rust code to render Markdown.
What now?
We are implementing the change in baby steps. They are as follows:
- Provide initial implementation with Textile->Markdown translation layer
- In this phase, Textile is converted to Markdown and rendered by Markdown.
- No database changes have been made yet. This is purely visual.
- Test to see if there are any translation issues or bugs.
- You can still write textile, but most of Markdown syntax will work as well (it might get interfered with by the conversion layer, though)
- Convert all existing posts and interactions from Textile to Markdown and write changes to database.
- During this phase all new posts created will still be treated like Textile posts, but their Markdown representation will be written to the database.
- Posts will still be rendered by converting from Textile to Markdown
- During this phase, editing old posts will still be done using the Textile syntax.
- Finalize the conversion by removing Textile versions of old posts. Markdown will become the sole markup on the site.
We are currently at phase #3
Q&A
Can I already write Markdown?
Yes, but due to conversion layer in-between you might run into issues where Textile and Markdown syntax collides.
Can I write raw HTML?
No. It will simply be escaped and output as plain text.
OMG I spotted a bug!
Please reply to this thread and tell us about it! We expect things to break and be buggy, this is why we’re hesitant to write anything to the database just yet.
Have fun!