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