Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

remark-html

Package Overview
Dependencies
Maintainers
2
Versions
32
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

remark-html - npm Package Compare versions

Comparing version 11.0.2 to 12.0.0

types/index.d.ts

17

package.json
{
"name": "remark-html",
"version": "11.0.2",
"version": "12.0.0",
"description": "remark plugin to compile Markdown to HTML",

@@ -31,9 +31,11 @@ "license": "MIT",

],
"types": "types/index.d.ts",
"files": [
"types/index.d.ts",
"index.js"
],
"dependencies": {
"hast-util-sanitize": "^2.0.0",
"hast-util-sanitize": "^3.0.0",
"hast-util-to-html": "^7.0.0",
"mdast-util-to-hast": "^8.2.0",
"mdast-util-to-hast": "^9.0.0",
"xtend": "^4.0.1"

@@ -44,2 +46,3 @@ },

"commonmark.json": "^0.29.0",
"dtslint": "^3.0.0",
"is-hidden": "^1.0.0",

@@ -56,6 +59,7 @@ "nyc": "^15.0.0",

"to-vfile": "^6.0.0",
"xo": "^0.30.0"
"unified": "^9.0.0",
"xo": "^0.32.0"
},
"scripts": {
"format": "remark *.md -qfo && prettier --write \"**/*.js\" && xo --fix",
"format": "remark . -qfo --ignore-pattern test/ && prettier . --write && xo --fix",
"build-bundle": "browserify . -s remarkHtml > remark-html.js",

@@ -66,3 +70,4 @@ "build-mangle": "browserify . -s remarkHtml -p tinyify > remark-html.min.js",

"test-coverage": "nyc --reporter lcov tape test/index.js",
"test": "npm run format && npm run build && npm run test-coverage"
"test-types": "dtslint types",
"test": "npm run format && npm run build && npm run test-coverage && npm run test-types"
},

@@ -69,0 +74,0 @@ "nyc": {

@@ -76,15 +76,23 @@ # remark-html

All options except for `sanitize` are passed to
All options except for `sanitize` and `handlers` are passed to
[`hast-util-to-html`][to-html].
###### `options.handlers`
Object mapping [mdast][] [nodes][mdast-node] to functions handling them.
This option is passed to [`mdast-util-to-html`][to-mdast-handlers].
###### `options.sanitize`
How to sanitize the output (`Object` or `boolean`, default: `true`).
How to sanitize the output (`Object` or `boolean`, default: `true`):
If `false`, no HTML is sanitized, and dangerous HTML is left unescaped.
* `false`
— HTML is not sanitized, dangerous HTML persists
* `true`
— HTML is [`hast-util-sanitize`][sanitize] according to [GitHub’s sanitation
rules][github], dangerous HTML is dropped
* `Object`
— the object is treated as a `schema` for how to sanitize with
[`hast-util-sanitize`][sanitize], dangerous HTML is dropped
If `true` or an `object`, sanitation is done by [`hast-util-sanitize`][sanitize]
If an object is passed in, it’s given as a schema to `hast-util-sanitize`.
If `true`, input is sanitized according to [GitHub’s sanitation rules][github].
> Note that raw HTML in Markdown cannot be sanitized, so it’s removed.

@@ -133,3 +141,3 @@ > A schema can still be used to allow certain values from [integrations][]

— Transform emoji unicodes into html images
* [`remark-html-katex`](https://github.com/rokt33r/remark-math/blob/master/packages/remark-html-katex/readme.md)
* [`remark-html-katex`](https://github.com/remark/remark-math/blob/HEAD/packages/remark-html-katex/readme.md)
— Transform math to HTML with KaTeX

@@ -199,3 +207,3 @@ * [`remark-math`](https://github.com/rokt33r/remark-math)

[build-badge]: https://img.shields.io/travis/remarkjs/remark-html/master.svg
[build-badge]: https://img.shields.io/travis/remarkjs/remark-html/main.svg

@@ -230,7 +238,7 @@ [build]: https://travis-ci.org/remarkjs/remark-html

[contributing]: https://github.com/remarkjs/.github/blob/master/contributing.md
[contributing]: https://github.com/remarkjs/.github/blob/HEAD/contributing.md
[support]: https://github.com/remarkjs/.github/blob/master/support.md
[support]: https://github.com/remarkjs/.github/blob/HEAD/support.md
[coc]: https://github.com/remarkjs/.github/blob/master/code-of-conduct.md
[coc]: https://github.com/remarkjs/.github/blob/HEAD/code-of-conduct.md

@@ -243,5 +251,5 @@ [license]: license

[remark-options]: https://github.com/remarkjs/remark/tree/master/packages/remark-parse#options
[remark-options]: https://github.com/remarkjs/remark/tree/HEAD/packages/remark-parse#options
[remark-plugins]: https://github.com/remarkjs/remark/blob/master/doc/plugins.md#list-of-plugins
[remark-plugins]: https://github.com/remarkjs/remark/blob/HEAD/doc/plugins.md#list-of-plugins

@@ -252,3 +260,3 @@ [remark2rehype]: https://github.com/remarkjs/remark-rehype

[rehype-stringify]: https://github.com/rehypejs/rehype/tree/master/packages/rehype-stringify
[rehype-stringify]: https://github.com/rehypejs/rehype/tree/HEAD/packages/rehype-stringify

@@ -259,2 +267,4 @@ [raw]: https://github.com/rehypejs/rehype-raw

[mdast-node]: https://github.com/syntax-tree/mdast#nodes
[hast]: https://github.com/syntax-tree/hast

@@ -264,2 +274,4 @@

[to-mdast-handlers]: https://github.com/syntax-tree/mdast-util-to-hast#optionshandlers
[sanitize]: https://github.com/syntax-tree/hast-util-sanitize

@@ -266,0 +278,0 @@

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc