Research
Security News
Malicious npm Packages Inject SSH Backdoors via Typosquatted Libraries
Socket’s threat research team has detected six malicious npm packages typosquatting popular libraries to insert SSH backdoors.
remark-lint-docusaurus-empty-lines-around-admonition-content
Advanced tools
remark-lint rule to warn when an admonition does not have empty lines around its content
remark-lint
rule to warn when an admonition does not have empty lines around its content.
Useful to prevent shooting yourself in the foot when using Docusaurus and Prettier (see Admonitions – Usage with Prettier).
This package is a unified (remark) plugin, specifically a remark-lint
rule.
Lint rules check markdown code style.
This package is ESM only.
In Node.js (16.0+), install with npm:
npm install --save-dev remark-lint-docusaurus-empty-lines-around-admonition-content
On the API:
import {read} from 'to-vfile'
import {reporter} from 'vfile-reporter'
import {remark} from 'remark'
import remarkLint from 'remark-lint'
import remarkLintDocusaurusEmptyLinesAroundAdmonitionContent from 'remark-lint-docusaurus-empty-lines-around-admonition-content'
main()
async function main() {
const file = await remark()
.use(remarkLint)
.use(remarkLintDocusaurusEmptyLinesAroundAdmonitionContent)
.process(await read('example.md'))
console.error(reporter(file))
}
On the CLI:
remark --use remark-lint --use remark-lint-docusaurus-empty-lines-around-admonition-content example.md
On the CLI in a config file (here a package.json
):
…
"remarkConfig": {
"plugins": [
…
"remark-lint",
+ "remark-lint-docusaurus-empty-lines-around-admonition-content",
…
]
}
…
unified().use(remarkLintNoUnneededFullReferenceLink[, config])
This rule supports standard configuration that all remark lint rules accept (such as false
to turn it off or [1, options]
to configure it).
There are no options.
See test/test.md or run the test with npm test
.
FAQs
remark-lint rule to warn when an admonition does not have empty lines around its content
The npm package remark-lint-docusaurus-empty-lines-around-admonition-content receives a total of 1 weekly downloads. As such, remark-lint-docusaurus-empty-lines-around-admonition-content popularity was classified as not popular.
We found that remark-lint-docusaurus-empty-lines-around-admonition-content 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.
Research
Security News
Socket’s threat research team has detected six malicious npm packages typosquatting popular libraries to insert SSH backdoors.
Security News
MITRE's 2024 CWE Top 25 highlights critical software vulnerabilities like XSS, SQL Injection, and CSRF, reflecting shifts due to a refined ranking methodology.
Security News
In this segment of the Risky Business podcast, Feross Aboukhadijeh and Patrick Gray discuss the challenges of tracking malware discovered in open source softare.