
Research
/Security News
Toptal’s GitHub Organization Hijacked: 10 Malicious Packages Published
Threat actors hijacked Toptal’s GitHub org, publishing npm packages with malicious payloads that steal tokens and attempt to wipe victim systems.
markdown-it-async
Advanced tools
Enhance markdown-it
to support async highlight function.
This package is a wrapper on top of markdown-it
instead of a fork. Updates from markdown-it
will be reflected without as transient dependencies.
import MarkdownItAsync from 'markdown-it-async'
const md = MarkdownItAsync({
async highlight(code, lang) {
const { codeToHtml } = await import('shiki')
return await codeToHtml(code, { lang, theme: 'vitesse-dark' })
}
})
// Note you need to use `renderAsync` instead of `render`
const html = await md.renderAsync(markdown)
This package is a thin wrapper around markdown-it
to support async highlight function. It uses the approach suggested in markdown-it
's docs, by putting placeholders in sync mode and then replace them with async results.
The goal is to make it easy to use and absorb the "hack" into the library itself.
MIT License © 2024-PRESENT Anthony Fu
FAQs
Enhance markdown-it to support async highlight function.
The npm package markdown-it-async receives a total of 9,403 weekly downloads. As such, markdown-it-async popularity was classified as popular.
We found that markdown-it-async demonstrated a healthy version release cadence and project activity because the last version was released less than 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.
Research
/Security News
Threat actors hijacked Toptal’s GitHub org, publishing npm packages with malicious payloads that steal tokens and attempt to wipe victim systems.
Research
/Security News
Socket researchers investigate 4 malicious npm and PyPI packages with 56,000+ downloads that install surveillance malware.
Security News
The ongoing npm phishing campaign escalates as attackers hijack the popular 'is' package, embedding malware in multiple versions.