[Feature Request] oEmbed for Frontend based playgrounds and videos
Closed this issue · 6 comments
For front based articles
Runnable is not needed but codepen.
Example:
https://codepen.io/IamManchanda/full/eWKPqE/
https://www.youtube.com/watch?v=FKzzaWR6j2M
What oEmbed look to do is this:
- You add a URL
- You press space and enter
- oEmbed will fetch and put the embedded URL in it
Site using them => Medium, Scotch.io and many others
Hi @IamManchanda :)
We do actually have that for youtube videos, but not for CodePen. I'll relay your feedback to the product team. By the way, you can also add viewers for front end though so it's not necessary to use CodePen.
A viewer is
aan HTTP service that renders content from the runner to an <iframe> inside the playground page. You can create your own HTTP server from your code or use a simplified server given by Tech.io.
@sidsharma27 Where can I get a simplified server from tech.io?
Edit: I don't need it, check comment below!
Secondly, Codepen is popular for frontend embedding so better would be codepen!
BTW Codepen has a debug mode too
https://s.codepen.io/IamManchanda/debug/eWKPqE/ZoMBajmdNEWk
so yes I can use their server for iframe too!
But still having Codepen embedding would be useful for community!
Will let the product team know and will update you accordingly :) Thanks for brining it to our attention!
Adding links based on talk with Thibaud Jobert
This may help you guys implementing the same!
https://blog.codepen.io/documentation/features/embedded-pens/
Example embed codepen => https://codepen.io/IamManchanda/embed/GMWoWB/
We've added oEmbed, but we are using a whitelist. For now, we don't want to support Codepen embeds in Tech.io playgrounds.