Deactivate Kirbytext, use Markdown only

Hello,

it is possible to deactivate the kirbytext for all textelements and use pure markdown instead (extra)? The problem here is, that our react frontend is not made for parsing kirbytext, and I do not want to reinvent the wheel, so far Iā€™ve modified Form.php to parse kirbytext that is coming via the api. But for the fb_builder display fields it is not possible, somehow.

  • R

What exactly do you mean? Make the buttons return Markdown instead of Kirbytext?

If you set

return [
    'debug' => true,
    'panel' => [
        'kirbytext' => false,
    ],
    
];

in your config, Kirby will use Markdown instead of Kirbytags.

wow. Thank you very much :smiley:

Hello again,

so Iā€™ve added the ā€˜panelā€™ => kirbytext = false
and itā€™s working for basic markdown elements such as ā€œlinkā€
Unfortunately for ā€œimageā€ itā€™s still kirbytext

Iā€™ve activated markdown extra

Strange, it works for me and add this code:

![](bildschirmfoto-2020-07-07-um-13.27.03.png)

yes, the code works of course. But if I click on the ā€œadd imageā€ icon, kirbytext will show up and the customer needs to rewrite the code. This is unpractical in production for non-tech people.

No, what I meant is if I insert an image into a textarea field, the above markdown is the result. It even works with drag&drop.

Of course, kirbytext already stored in the field is not automatically converted.

Tested with 3.4.

Iā€™m only getting the raw url if I drag&drop files or images.
Iā€™m using 3.3.5

Just updated to 3.4.0
Still no markdown text for images and files

We are talking about adding images to a standard textarea field, arenā€™t we? Not some sort of custom field?

with textarea itā€™s working fine.
we are using ā€˜markdownā€™ textelements. thatā€™s strange, because markdown is using kirbytext :smiley:

You mean the markdown field plugin? Well, thatā€™s another story then and if it doesnā€™t support it, then consider using the textarea field instead.

but the textarea field is not showing markdown in the field itself :smiley: Thatā€™s actually not good ui for the editors

If youā€™re looking for a ā€œwysiwyg fieldā€ for better authoring experience, check out https://github.com/getkirby/editor instead of textarea field that basically allows editors to write in kirbytext flavoured markdown.

This field doesnā€™t output markdown though.

but can I deactivate Kirbytext on this new editor?

The editor field doesnā€™t use kirbytext. In fact it uses an entire new paradigm of storing its content in ā€œblocksā€ which are saved as json in the backend. You need to render these blocks in the frontend.

1 Like