Socket
Socket
Sign inDemoInstall

micromark-util-html-tag-name

Package Overview
Dependencies
Maintainers
1
Versions
8
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

micromark-util-html-tag-name - npm Package Compare versions

Comparing version 1.0.0 to 1.1.0

8

index.d.ts

@@ -9,3 +9,3 @@ /**

* This is copied from:
* <https://spec.commonmark.org/0.29/#html-blocks>.
* <https://spec.commonmark.org/0.30/#html-blocks>.
*/

@@ -19,8 +19,6 @@ export const htmlBlockNames: string[]

* This module is copied from:
* <https://spec.commonmark.org/0.29/#html-blocks>.
* <https://spec.commonmark.org/0.30/#html-blocks>.
*
* Note that `textarea` is not available in `CommonMark@0.29` but has been
* merged to the primary branch and is slated to be released in the next release
* of CommonMark.
* Note that `textarea` was added in `CommonMark@0.30`.
*/
export const htmlRawNames: string[]

@@ -9,3 +9,3 @@ /**

* This is copied from:
* <https://spec.commonmark.org/0.29/#html-blocks>.
* <https://spec.commonmark.org/0.30/#html-blocks>.
*/

@@ -63,3 +63,2 @@ export const htmlBlockNames = [

'section',
'source',
'summary',

@@ -84,8 +83,6 @@ 'table',

* This module is copied from:
* <https://spec.commonmark.org/0.29/#html-blocks>.
* <https://spec.commonmark.org/0.30/#html-blocks>.
*
* Note that `textarea` is not available in `CommonMark@0.29` but has been
* merged to the primary branch and is slated to be released in the next release
* of CommonMark.
* Note that `textarea` was added in `CommonMark@0.30`.
*/
export const htmlRawNames = ['pre', 'script', 'style', 'textarea']
{
"name": "micromark-util-html-tag-name",
"version": "1.0.0",
"version": "1.1.0",
"description": "micromark utility with list of html tag names",

@@ -5,0 +5,0 @@ "license": "MIT",

@@ -26,3 +26,4 @@ # micromark-util-html-tag-name

[npm][]:
This package is [ESM only][esm].
In Node.js (version 12.20+, 14.14+, 16.0+, 18.0+), install with [npm][]:

@@ -33,2 +34,16 @@ ```sh

In Deno with [`esm.sh`][esmsh]:
```js
import {htmlBlockNames, htmlRawNames} from 'https://esm.sh/micromark-util-html-tag-name@1'
```
In browsers with [`esm.sh`][esmsh]:
```html
<script type="module">
import {htmlBlockNames, htmlRawNames} from 'https://esm.sh/micromark-util-html-tag-name@1?bundle'
</script>
```
## Use

@@ -51,22 +66,20 @@

List of lowercase HTML tag names (`string[]`) which when parsing HTML (flow),
result in more relaxed rules (condition 6): because they are known blocks, the
HTML-like syntax doesn’t have to be strictly parsed.
List of lowercase HTML tag names (`Array<string>`) which when parsing HTML
(flow), result in more relaxed rules (condition 6): because they are known
blocks, the HTML-like syntax doesn’t have to be strictly parsed.
For tag names not in this list, a more strict algorithm (condition 7) is used
to detect whether the HTML-like syntax is seen as HTML (flow) or not.
This is copied from: <https://spec.commonmark.org/0.29/#html-blocks>.
This is copied from: <https://spec.commonmark.org/0.30/#html-blocks>.
### `htmlRawNames`
List of lowercase HTML tag names (`string[]`) which when parsing HTML (flow),
result in HTML that can include lines w/o exiting, until a closing tag also in
this list is found (condition 1).
List of lowercase HTML tag names (`Array<string>`) which when parsing HTML
(flow), result in HTML that can include lines w/o exiting, until a closing tag
also in this list is found (condition 1).
This is copied from:
<https://spec.commonmark.org/0.29/#html-blocks>.
<https://spec.commonmark.org/0.30/#html-blocks>.
Note that `textarea` is not available in `CommonMark@0.29` but has been merged
to the primary branch and is slated to be released in the next release of
CommonMark.
Note that `textarea` was added in `CommonMark@0.30`.

@@ -118,2 +131,6 @@ ## Security

[esm]: https://gist.github.com/sindresorhus/a39789f98801d908bbc7ff3ecc99d99c
[esmsh]: https://esm.sh
[chat-badge]: https://img.shields.io/badge/chat-discussions-success.svg

@@ -120,0 +137,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