marked-base-url 1.1.0 → 1.1.1

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.
Files changed (2) hide show
  1. package/README.md +11 -6
  2. package/package.json +16 -16
package/README.md CHANGED
@@ -5,15 +5,20 @@ Prefix relative url with base url.
5
5
  # Usage
6
6
 
7
7
  ```js
8
+ // ESM
8
9
  import {marked} from "marked";
9
10
  import {baseUrl} from "marked-base-url";
10
11
 
11
- // or UMD script
12
- // <script src="https://cdn.jsdelivr.net/npm/marked/lib/marked.umd.js"></script>
13
- // <script src="https://cdn.jsdelivr.net/npm/marked-base-url/lib/index.umd.js"></script>
14
-
15
12
  marked.use(baseUrl("https://example.com/folder/"));
16
-
17
- marked.parse("[my url](./relative/path)");
13
+ const html = marked.parse("[my url](./relative/path)");
18
14
  // <p><a href="https://example.com/folder/relative/path">my url</a></p>
15
+
16
+ // BROWSER
17
+ <script src="https://cdn.jsdelivr.net/npm/marked"></script>
18
+ <script src="https://cdn.jsdelivr.net/npm/marked-base-url"></script>
19
+ <script>
20
+ marked.use(markedBaseUrl.baseUrl("https://example.com/folder/"));
21
+ const html = marked.parse("[my url](./relative/path)");
22
+ // <p><a href="https://example.com/folder/relative/path">my url</a></p>
23
+ </script>
19
24
  ```
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "marked-base-url",
3
- "version": "1.1.0",
3
+ "version": "1.1.1",
4
4
  "description": "marked base url",
5
5
  "main": "./lib/index.cjs",
6
6
  "module": "./src/index.js",
@@ -41,27 +41,27 @@
41
41
  },
42
42
  "homepage": "https://github.com/markedjs/marked-base-url#readme",
43
43
  "peerDependencies": {
44
- "marked": ">= 4 < 10"
44
+ "marked": ">= 4 < 11"
45
45
  },
46
46
  "devDependencies": {
47
- "@babel/core": "^7.22.17",
48
- "@babel/preset-env": "^7.22.15",
47
+ "@babel/core": "^7.23.3",
48
+ "@babel/preset-env": "^7.23.3",
49
49
  "@semantic-release/changelog": "^6.0.3",
50
- "@semantic-release/commit-analyzer": "^10.0.4",
50
+ "@semantic-release/commit-analyzer": "^11.1.0",
51
51
  "@semantic-release/git": "^10.0.1",
52
- "@semantic-release/github": "^9.0.5",
53
- "@semantic-release/npm": "^10.0.5",
54
- "@semantic-release/release-notes-generator": "^11.0.7",
55
- "babel-jest": "^29.6.4",
56
- "eslint": "^8.49.0",
52
+ "@semantic-release/github": "^9.2.3",
53
+ "@semantic-release/npm": "^11.0.1",
54
+ "@semantic-release/release-notes-generator": "^12.1.0",
55
+ "babel-jest": "^29.7.0",
56
+ "eslint": "^8.53.0",
57
57
  "eslint-config-standard": "^17.1.0",
58
- "eslint-plugin-import": "^2.28.1",
59
- "eslint-plugin-n": "^16.1.0",
58
+ "eslint-plugin-import": "^2.29.0",
59
+ "eslint-plugin-n": "^16.3.1",
60
60
  "eslint-plugin-promise": "^6.1.1",
61
- "jest-cli": "^29.6.4",
62
- "marked": "^9.0.0",
63
- "rollup": "^3.29.1",
64
- "semantic-release": "^21.1.1",
61
+ "jest-cli": "^29.7.0",
62
+ "marked": "^10.0.0",
63
+ "rollup": "^4.3.0",
64
+ "semantic-release": "^22.0.7",
65
65
  "tsd": "^0.29.0"
66
66
  },
67
67
  "tsd": {