Product
Introducing SSO
Streamline your login process and enhance security by enabling Single Sign-On (SSO) on the Socket platform, now available for all customers on the Enterprise plan, supporting 20+ identity providers.
remark-deflist
Advanced tools
Readme
Remark plugin for adding support for pandoc-style definition lists to Markdown.
Adds three new node types to MDAST: descriptionlist
, descriptionterm
, and descriptiondetails
.
When using rehype, these will be stringified as dl
, dt
, and dd
respectively.
Mostly compatible with the pandoc/PHP Markdown Extra syntax. The only difference is that multi-paragraph descriptions are not currently supported.
This package is ESM only:
Node 12+ is needed to use it and it must be import
ed instead of require
d.
npm:
npm install remark-deflist
Term 1
: Definition 1
The example above will yield:
{
type: 'descriptionlist',
children: [
{
type: 'descriptionterm',
children: [{
type: 'text',
value: 'Term 1'
}]
},
{
type: 'descriptiondetails',
children: [{
type: 'text',
value: 'Definition 1'
}]
}
]
}
Term with *inline markup*
: Definition **1**
Lazy Initialization
: Achievement of compactness by not typing an extra line after the definition term.
Continuation
: Splitting a single paragraph
across multiple lines.
Lazy Continuation
: Ugliness
by not indenting text.
This is an example of multiple definitions for a single term.
Indent
: (*noun*) A whitespace to align text in a beautiful way.
: (*verb*) To add whitespace to make ugly code beautiful.
import { unified } from 'unified'
import markdown from 'remark-parse'
import html from 'rehype-stringify'
import remark2rehype from 'remark-rehype'
import meta from 'remark-meta'
unified()
.use(markdown)
.use(meta)
.use(remark2rehype)
.use(html)
MIT © Alex Shaw
FAQs
Remark plugin for pandoc-style definition lists.
The npm package remark-deflist receives a total of 755 weekly downloads. As such, remark-deflist popularity was classified as not popular.
We found that remark-deflist demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
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.
Product
Streamline your login process and enhance security by enabling Single Sign-On (SSO) on the Socket platform, now available for all customers on the Enterprise plan, supporting 20+ identity providers.
Security News
Tea.xyz, a crypto project aimed at rewarding open source contributions, is once again facing backlash due to an influx of spam packages flooding public package registries.
Security News
As cyber threats become more autonomous, AI-powered defenses are crucial for businesses to stay ahead of attackers who can exploit software vulnerabilities at scale.