pantsdown 1.10.2 → 1.10.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -1,5 +1,3 @@
1
- <!-- Up to marked@9.1.3 -->
2
-
3
1
  # Pantsdown
4
2
 
5
3
  <img src="https://raw.githubusercontent.com/wallpants/pantsdown/main/docs/github.svg" height="60px" align="right" />
@@ -15,7 +13,8 @@ feel free to open an issue.
15
13
 
16
14
  ## 📦 Installation
17
15
 
18
- 🚨 Pantsdown is distributed only as a TypeScript module. This means you'll need a bundler to handle transpilation.
16
+ This package is distributed only as a TypeScript module.
17
+ This means you'll need a bundler to handle transpilation.
19
18
  See below for usage examples.
20
19
 
21
20
  ```sh
@@ -27,6 +26,9 @@ npm install pantsdown
27
26
 
28
27
  ## 💻 Usage
29
28
 
29
+ 🚨 Pantsdown does not sanitize the output HTML. If you are processing potentially unsafe strings,
30
+ it's recommended you use a sanitization library like [DOMPurify](https://github.com/cure53/DOMPurify).
31
+
30
32
  ### Styles
31
33
 
32
34
  For styles to be properly applied, either the element containing the generated html or one of its parents
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "pantsdown",
3
- "version": "1.10.2",
3
+ "version": "1.10.4",
4
4
  "author": "wallpants",
5
5
  "description": "Markdown to 'GitHub HTML' parser",
6
6
  "license": "MIT",
@@ -27,7 +27,7 @@
27
27
  }
28
28
  },
29
29
  "scripts": {
30
- "format": "prettier **.{md,ts,css} -w",
30
+ "format": "prettier **/*.{md,ts,css} -w",
31
31
  "lint": "tsc && eslint . --ext ts --report-unused-disable-directives --max-warnings 0",
32
32
  "commit": "cz",
33
33
  "docs:build": "bun run docs/build.ts"
@@ -43,15 +43,15 @@
43
43
  },
44
44
  "devDependencies": {
45
45
  "@happy-dom/global-registrator": "^12.10.3",
46
- "@typescript-eslint/eslint-plugin": "^6.9.1",
47
- "@typescript-eslint/parser": "^6.9.1",
46
+ "@typescript-eslint/eslint-plugin": "^6.11.0",
47
+ "@typescript-eslint/parser": "^6.11.0",
48
48
  "bun-types": "latest",
49
49
  "commitizen": "^4.3.0",
50
50
  "cz-conventional-changelog": "^3.3.0",
51
- "eslint": "^8.53.0",
52
- "prettier": "^3.0.3",
53
- "prettier-plugin-organize-imports": "^3.2.3",
54
- "semantic-release": "^22.0.7",
51
+ "eslint": "^8.54.0",
52
+ "prettier": "^3.1.0",
53
+ "prettier-plugin-organize-imports": "^3.2.4",
54
+ "semantic-release": "^22.0.8",
55
55
  "typescript": "5.2.2"
56
56
  }
57
57
  }
@@ -126,6 +126,6 @@ export const block: Record<BlockRuleNames, RegExp> = {
126
126
  table: block_table,
127
127
  lheading: block_lheading,
128
128
  paragraph: block_paragraph,
129
- footnote: /^\[\^([^\]\n]+)\]:(?:[ \t]+|[\n]*?|$)([^\[\n]*?(?:\n|$)(?:[\n]*?[ ]{4,}[^\[\n]*)*)/,
129
+ footnote: /^\[\^([^\]\n]+)\]:(?:[ \t]+|[\n]*?|$)([^\n]*?(?:\n|$)(?:[\n]*?[ ]{4,}[^\n]*)*)/,
130
130
  text: /^[^\n]+/,
131
131
  };