@scalar/openapi-to-markdown 0.2.37 → 0.2.39

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/CHANGELOG.md CHANGED
@@ -1,5 +1,33 @@
1
1
  # @scalar/openapi-to-markdown
2
2
 
3
+ ## 0.2.39
4
+
5
+ ### Patch Changes
6
+
7
+ - Updated dependencies [e1cdd00]
8
+ - @scalar/openapi-parser@0.21.1
9
+ - @scalar/oas-utils@0.4.31
10
+ - @scalar/components@0.14.36
11
+
12
+ ## 0.2.38
13
+
14
+ ### Patch Changes
15
+
16
+ - 02085ef: refactor: use upgrade function from @scalar/openapi-upgrader
17
+ - Updated dependencies [6221e4a]
18
+ - Updated dependencies [005fba9]
19
+ - Updated dependencies [a1f865c]
20
+ - Updated dependencies [a1f865c]
21
+ - Updated dependencies [2d612e4]
22
+ - Updated dependencies [dcf50ef]
23
+ - Updated dependencies [02085ef]
24
+ - @scalar/openapi-upgrader@0.1.0
25
+ - @scalar/types@0.2.16
26
+ - @scalar/openapi-parser@0.21.0
27
+ - @scalar/oas-utils@0.4.30
28
+ - @scalar/snippetz@0.4.10
29
+ - @scalar/components@0.14.35
30
+
3
31
  ## 0.2.37
4
32
 
5
33
  ### Patch Changes
@@ -1 +1 @@
1
- {"version":3,"file":"create-markdown-from-openapi.d.ts","sourceRoot":"","sources":["../src/create-markdown-from-openapi.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,uBAAuB,CAAA;AAYpD,KAAK,WAAW,GAAG,OAAO,CAAC,QAAQ,GAAG,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,GAAG,MAAM,CAAA;AAEtE,wBAAsB,qBAAqB,CAAC,KAAK,EAAE,WAAW,mBAyB7D;AAED,wBAAsB,yBAAyB,CAAC,OAAO,EAAE,WAAW,mBAEnE;AAED,wBAAsB,gBAAgB,CAAC,IAAI,EAAE,MAAM,GAAG,OAAO,CAAC,MAAM,CAAC,CAYpE"}
1
+ {"version":3,"file":"create-markdown-from-openapi.d.ts","sourceRoot":"","sources":["../src/create-markdown-from-openapi.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,uBAAuB,CAAA;AAepD,KAAK,WAAW,GAAG,OAAO,CAAC,QAAQ,GAAG,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,GAAG,MAAM,CAAA;AAEtE,wBAAsB,qBAAqB,CAAC,KAAK,EAAE,WAAW,mBAyB7D;AAED,wBAAsB,yBAAyB,CAAC,OAAO,EAAE,WAAW,mBAEnE;AAED,wBAAsB,gBAAgB,CAAC,IAAI,EAAE,MAAM,GAAG,OAAO,CAAC,MAAM,CAAC,CAYpE"}
@@ -1,19 +1,20 @@
1
- import { upgrade as n, dereference as i } from "@scalar/openapi-parser";
2
- import { minify as a } from "html-minifier-terser";
3
- import p from "rehype-parse";
4
- import s from "rehype-remark";
5
- import u from "rehype-sanitize";
6
- import c from "remark-gfm";
7
- import f from "remark-stringify";
8
- import { unified as l } from "unified";
9
- import { createSSRApp as y } from "vue";
10
- import { renderToString as d } from "vue/server-renderer";
11
- import g from "./components/MarkdownReference.vue.js";
12
- async function h(e) {
13
- const { specification: r } = n(e), { schema: t } = await i(r), o = y(g, {
1
+ import { normalize as n, dereference as i } from "@scalar/openapi-parser";
2
+ import { upgrade as a } from "@scalar/openapi-upgrader";
3
+ import { minify as p } from "html-minifier-terser";
4
+ import s from "rehype-parse";
5
+ import u from "rehype-remark";
6
+ import c from "rehype-sanitize";
7
+ import f from "remark-gfm";
8
+ import l from "remark-stringify";
9
+ import { unified as y } from "unified";
10
+ import { createSSRApp as d } from "vue";
11
+ import { renderToString as g } from "vue/server-renderer";
12
+ import h from "./components/MarkdownReference.vue.js";
13
+ async function w(e) {
14
+ const r = a(n(e), "3.1"), { schema: t } = await i(r), o = d(h, {
14
15
  content: t
15
- }), m = await d(o);
16
- return a(m, {
16
+ }), m = await g(o);
17
+ return p(m, {
17
18
  removeComments: !0,
18
19
  removeEmptyElements: !0,
19
20
  collapseWhitespace: !0,
@@ -25,17 +26,17 @@ async function h(e) {
25
26
  useShortDoctype: !0
26
27
  });
27
28
  }
28
- async function P(e) {
29
- return w(await h(e));
29
+ async function R(e) {
30
+ return S(await w(e));
30
31
  }
31
- async function w(e) {
32
- const r = await l().use(p, { fragment: !0 }).use(c).use(u).use(s).use(f, {
32
+ async function S(e) {
33
+ const r = await y().use(s, { fragment: !0 }).use(f).use(c).use(u).use(l, {
33
34
  bullet: "-"
34
35
  }).process(e);
35
36
  return String(r);
36
37
  }
37
38
  export {
38
- h as createHtmlFromOpenApi,
39
- P as createMarkdownFromOpenApi,
40
- w as markdownFromHtml
39
+ w as createHtmlFromOpenApi,
40
+ R as createMarkdownFromOpenApi,
41
+ S as markdownFromHtml
41
42
  };
package/package.json CHANGED
@@ -16,7 +16,7 @@
16
16
  "llm",
17
17
  "swagger"
18
18
  ],
19
- "version": "0.2.37",
19
+ "version": "0.2.39",
20
20
  "engines": {
21
21
  "node": ">=20"
22
22
  },
@@ -54,20 +54,21 @@
54
54
  "remark-stringify": "^11.0.0",
55
55
  "unified": "^11.0.4",
56
56
  "vue": "^3.5.17",
57
- "@scalar/components": "0.14.34",
58
57
  "@scalar/helpers": "0.0.11",
59
- "@scalar/oas-utils": "0.4.29",
60
- "@scalar/openapi-parser": "0.20.6",
58
+ "@scalar/components": "0.14.36",
59
+ "@scalar/openapi-parser": "0.21.1",
60
+ "@scalar/openapi-upgrader": "0.1.0",
61
+ "@scalar/oas-utils": "0.4.31",
61
62
  "@scalar/openapi-types": "0.3.7",
62
- "@scalar/types": "0.2.15",
63
- "@scalar/snippetz": "0.4.9"
63
+ "@scalar/snippetz": "0.4.10",
64
+ "@scalar/types": "0.2.16"
64
65
  },
65
66
  "devDependencies": {
66
67
  "@hono/node-server": "^1.11.0",
67
68
  "@types/html-minifier-terser": "^7.0.2",
68
69
  "@vitejs/plugin-vue": "6.0.1",
69
70
  "@vue/test-utils": "^2.4.1",
70
- "hono": "^4.6.5",
71
+ "hono": "4.9.7",
71
72
  "vite": "7.1.5",
72
73
  "vue": "^3.5.17",
73
74
  "@scalar/build-tooling": "0.2.7",