-
-
Notifications
You must be signed in to change notification settings - Fork 50
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Figure with iframe tags break markdown preview #87
Comments
@Kopnu Use Remark plugin import oembed from '@agentofuser/remark-oembed';
<MarkdownPreview
source={source}
remarkPlugins={[oembed]}
/> Hey this is a nice youtube video about making modern react apps with gatsby:
https://www.youtube.com/watch?v=GN0xHSk2P8Q
Check it out 👆 output Hey this is a nice youtube video about making modern react apps with gatsby:
<iframe
width="480"
height="270"
src="https://www.youtube.com/embed/GN0xHSk2P8Q?feature=oembed"
frameborder="0"
allow="accelerometer;
autoplay;
encrypted-media;
gyroscope;
picture-in-picture"
allowfullscreen>
</iframe>
Check it out 👆 |
@jaywcjlove I don’t know, but I’m really doing something wrong ... 🤔 Where can I find any information on how this should work? Or maybe how can i create my own plugin? P.s. I also tried to install a remark and it didn't help |
The plugin is too old |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Hi, I found a problem with figure/iframe html tags. When You try to add md text right after that, it doesn't compile.
It's easy to reproduce on codesandbox.
Maybe I'm doing the wrong thing and You know a better way to embed a video in a Markdown preview?
Versions:
Some examples:
For other tags, I have to add extra "\n " and it will work...

The text was updated successfully, but these errors were encountered: