saberland/saber

Do you want to work on this issue?

You can request for a bounty in order to promote it!

Disable Markdown rendering in Vue-in-Markdown elements #516

krmax44 posted onGitHub

<!-- Please don't delete this template or we'll close your issue -->

<!-- Before creating an issue please make sure you are using the latest version of Saber. -->

<!-- Issues which contain questions or support requests will be closed. -->

<!-- Please ask questions via following several ways. -->

<!-- https://chat.saber.land/ -->

<!-- https://stackoverflow.com/questions/ask?tags=saberjs -->

Bug report

Markdown in Vue-in-Markdown components gets rendered.

Steps to reproduce

# Hello!

<my-component>Works!</my-component>
<my-component>
  Doesn't work!
</my-component>
<my-component>
  # Hello
</my-component>

<button># A regular HTML button works just fine</button>

<!-- If you are reporting a bug that can ONLY be reproduced on your repository, PLEASE provide this repo link. That takes guessing work out of the way and saves us time. -->

<!-- You can also use this CodeSandbox starter https://bit.ly/2IlcpNF -->

What is expected?

<h1>Hello!</h1>

<my-component>Works!</my-component>

<my-component>Doesn't work!</my-component>

<my-component># Hello</my-component>

<button># A regular HTML button works just fine</button>

What is actually happening?

Gets rendered to:

<h1>Hello!</h1>

<my-component>Works!</my-component>

<my-component><p>Doesn't work!</p></my-component>

<my-component><h1>Hello</h1></my-component>

<button># A regular HTML button works just fine</button>

Other relevant information

  • Result of running saber -v: latest
  • Browser version (optional):
  • Is Saber a global or local install? local
  • Which package manager did you use for the install? yarn
  • Does this issue occur when all plugins are disabled? ye

That should be possible by modifying the html renderer in markdown-it, I haven't tested it tho.

posted by egoist over 5 years ago

Fund this Issue

$0.00
Funded
Only logged in users can fund an issue

Pull requests