Ridiculously simple zero-config markdown displayer
ISC License
Bot releases are visible (Hide)
Published by zerodevx about 3 years ago
MutationObserver
coderender()
will not re-stamp the DOM if there are no changes nowPrism
highlight asynchronously with Web Workers; fall back to synchronous if unsupportedmarked
to v3
clearDom()
is deprecated since partial rendering inserts or replaces insteadstampDom()
is deprecated; operation split into stampStyles()
and stampBody()
respectivelymakeFrag()
is deprecated and replaced with makeNode()
Published by zerodevx over 3 years ago
Published by zerodevx over 3 years ago
/docs
Published by zerodevx over 3 years ago
Published by zerodevx over 3 years ago
Published by zerodevx almost 4 years ago
Published by zerodevx almost 4 years ago
Published by zerodevx almost 4 years ago
V2 is released! 🎉
Some breaking changes are introduced. If you're migrating from V1 to V2, please read the migration guide.
V1 has been moved into its separate tree - a final maintenance release is published, but in general no more updates will be done.
It is highly recommended to upgrade to V2 - it is modern, much cleaner and much easier to reason with. To get some context as to why, please read the V2 release candidate release notes.
V2 features include:
src
src
changesCheck out the V2 docs: https://zerodevx.github.io/zero-md/
Published by zerodevx almost 4 years ago
Published by zerodevx almost 4 years ago
src
attribute change behaviour.tick()
function.goto()
function.Published by zerodevx about 4 years ago
no-shadow
is immutable and must be set at element creation timePublished by zerodevx about 4 years ago
no-shadow
Published by zerodevx about 4 years ago
V2 is a re-write. It is feature-complete, so all existing V1 features (including those from contributors - thank you!) should also be found here. Some breaking changes are introduced.
Component changes:
<xmp>
tag support is dropped; use <script type="text/markdown">
instead - https://github.com/zerodevx/zero-md/pull/29#issuecomment-673305798
data-dedent
attribute like this: <script type="text/markdown" data-dedent>
<zero-md>
will always try to load from src
attribute first; if it's falsy (no src
attribute, src
download fails, src
is an empty file etc.), then it falls-back on <script type="text/markdown">
.css-urls
, prism-url
and marked-url
are removed. <zero-md>
only accepts src
, manual-render
and no-shadow
.<template>
tags should now be used only to house styles. That includes <link rel="stylesheet">
(for loading external stylesheets), and standard <style>
tags.<template data-merge="append | prepend">
- https://github.com/zerodevx/zero-md/issues/34
window.ZeroMdConfig
object instead.src
path - fixes https://github.com/zerodevx/zero-md/issues/22
zero-md-marked-ready
and zero-md-prism-ready
custom events are dropped. Use zero-md-ready
instead.<zero-md>
now automatically re-renders if src
changes, and manual-render
is not set - https://github.com/zerodevx/zero-md/issues/26
<script type="text/markdown">
are not observed. This is best handled outside the remit of <zero-md>
through a MutationObserver
recipe.zero-md-error
custom event is now emitted if non-fatal HTTP errors are detected - https://github.com/zerodevx/zero-md/issues/31 - more will be written on this.Tooling changes:
web-component-tester
and selenium
and headless-chrome
with bower
with fixture-element
and all that bloatware. Really, you just need mocha
and chai asserts
and run them off your browser.standardjs
and move on.HTMLImports
(good riddance) and fixed package.json
. ES imports should now work as expected - fixes https://github.com/zerodevx/zero-md/issues/25
master
to main
.Published by zerodevx about 4 years ago
<script type="text/markdown">
with dedenting - thanks @bennypowers! (ref: #29)Published by zerodevx over 4 years ago
Published by zerodevx almost 5 years ago
Published by zerodevx about 5 years ago
Published by zerodevx over 5 years ago
ZeroMd.config
global to set default values applying to all instances of <zero-md>
in the document. (Ref: PR#12) - thanks @bennypowers!Published by zerodevx over 5 years ago