@svelte-parts/markdown
TypeScript icon, indicating that this package has built-in type declarations

0.0.23 • Public • Published

@svelte-parts/markdown

For markdown blocks

Demo

Try it out in the svelte REPL

Install

npm install @svelte-parts/markdown

Usage

<Markdown>
# Title

## List

1. one
2. two
3. three
</Markdown>

Uses marked to convert to HTML and is sanitized with dompurify. Both can be configured with the optional attributes:

  • dompurifyConfig (type: DOMPurify.Config)
  • markedExtensions (type: MarkedExtension[])
  • markedOptions (type: MarkedOptions)

Versions

Current Tags

VersionDownloads (Last 7 Days)Tag
0.0.230latest

Version History

VersionDownloads (Last 7 Days)Published
0.0.230
0.0.220
0.0.210
0.0.200
0.0.190

Package Sidebar

Install

npm i @svelte-parts/markdown

Weekly Downloads

0

Version

0.0.23

License

MIT

Unpacked Size

2.36 kB

Total Files

5

Last publish

Collaborators

  • idris-maps