On Yak Shaving and md-block, a new HTML element for Markdown

Lea Verou made a Web Component for processing Markdown. Looks like there were a couple of others out there already, but I agree with Lea in that this is a good use case for the light DOM (as opposed …


This content originally appeared on CSS-Tricks and was authored by Chris Coyier

Lea Verou made a Web Component for processing Markdown. Looks like there were a couple of others out there already, but I agree with Lea in that this is a good use case for the light DOM (as opposed to the shadow DOM that is normally quite useful for web components), and that’s what Lea’s does. The output is HTML so I can imagine it’s ideal you can style it on the page like any other type rather than have to deal with that shadow DOM. I still feel like the styling stories for shadow DOM all kinda suck.

The story of how it came to be is funny and highly relatable. You just want to build one simple thing and it turns out you have to do 15 other things and it takes the better part of a week.

The demos on the landing page for <md-block> shoot over to CodePen using the prefill API. Figured I’d embed one here too:

To Shared LinkPermalink on CSS-Tricks


This content originally appeared on CSS-Tricks and was authored by Chris Coyier


Print Share Comment Cite Upload Translate Updates
APA

Chris Coyier | Sciencx (2021-12-29T16:03:44+00:00) On Yak Shaving and md-block, a new HTML element for Markdown. Retrieved from https://www.scien.cx/2021/12/29/on-yak-shaving-and-md-block-a-new-html-element-for-markdown-2/

MLA
" » On Yak Shaving and md-block, a new HTML element for Markdown." Chris Coyier | Sciencx - Wednesday December 29, 2021, https://www.scien.cx/2021/12/29/on-yak-shaving-and-md-block-a-new-html-element-for-markdown-2/
HARVARD
Chris Coyier | Sciencx Wednesday December 29, 2021 » On Yak Shaving and md-block, a new HTML element for Markdown., viewed ,<https://www.scien.cx/2021/12/29/on-yak-shaving-and-md-block-a-new-html-element-for-markdown-2/>
VANCOUVER
Chris Coyier | Sciencx - » On Yak Shaving and md-block, a new HTML element for Markdown. [Internet]. [Accessed ]. Available from: https://www.scien.cx/2021/12/29/on-yak-shaving-and-md-block-a-new-html-element-for-markdown-2/
CHICAGO
" » On Yak Shaving and md-block, a new HTML element for Markdown." Chris Coyier | Sciencx - Accessed . https://www.scien.cx/2021/12/29/on-yak-shaving-and-md-block-a-new-html-element-for-markdown-2/
IEEE
" » On Yak Shaving and md-block, a new HTML element for Markdown." Chris Coyier | Sciencx [Online]. Available: https://www.scien.cx/2021/12/29/on-yak-shaving-and-md-block-a-new-html-element-for-markdown-2/. [Accessed: ]
rf:citation
» On Yak Shaving and md-block, a new HTML element for Markdown | Chris Coyier | Sciencx | https://www.scien.cx/2021/12/29/on-yak-shaving-and-md-block-a-new-html-element-for-markdown-2/ |

Please log in to upload a file.




There are no updates yet.
Click the Upload button above to add an update.

You must be logged in to translate posts. Please log in or register.