Socket
Book a DemoInstallSign in
Socket

@dragon-fish/md-block

Package Overview
Dependencies
Maintainers
1
Versions
2
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install
Package was removed
Sorry, it seems this package was removed from the registry

@dragon-fish/md-block

Cool stuff that lets you embed markdown in your HTML.

unpublished
latest
npmnpm
Version
0.1.1
Version published
Weekly downloads
0
Maintainers
1
Weekly downloads
 
Created
Source

Markdown Block

Cool stuff that lets you embed markdown in your HTML.

Just like this:

<markdown>
# Markdown Block

normal **bold** _italic_ ~~strikethrough~~
</markdown>

Installation

pnpm add @dragon-fish/md-block

Usage

Using package

// Simply import only, then you can use <markdown> tag in your HTML
import '@dragon-fish/md-block'

// Or sometimes you may need to using the API
import MarkdownBlock from '@dragon-fish/md-block'
const md = MarkdownBlock.createElement()
md.innerText = `
# Markdown Block

normal **bold** _italic_ ~~strikethrough~~
`
document.body.appendChild(md)

In browser

<!-- Simply load the script -->
<script src="https://unpkg.com/@dragon-fish/md-block"></script>
<markdown>
  <!-- some markdown here -->
</markdown>

<!-- Or sometimes you may need to using the API -->
<script type="module">
  import { default as MarkdownBlock } from 'https://unpkg.com/@dragon-fish/md-block?module'
  const md = MarkdownBlock.createElement()
  md.innerText = `
# Markdown Block

normal **bold** _italic_ ~~strikethrough~~
`
  document.body.appendChild(md)
</script>

Trivals

I created this package as a practice for using CustomElements. Although it doesn't have much use, it can indeed help you insert content written in markdown anywhere on the web page at any time.

FAQs

Package last updated on 18 Nov 2023

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts