docusaurus-plugin-openapi-docs 0.0.0-1000 → 0.0.0-1001
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/lib/index.js +3 -1
- package/package.json +2 -2
- package/src/index.ts +11 -5
package/lib/index.js
CHANGED
|
@@ -279,7 +279,9 @@ custom_edit_url: null
|
|
|
279
279
|
if (item.type === "info") {
|
|
280
280
|
if (!fs_1.default.existsSync(`${outputDir}/${item.id}.info.mdx`)) {
|
|
281
281
|
try {
|
|
282
|
-
|
|
282
|
+
(sidebarOptions === null || sidebarOptions === void 0 ? void 0 : sidebarOptions.categoryLinkSource) === "info" || infoTemplate // Only use utils template if set to "info" or if infoTemplate is set
|
|
283
|
+
? fs_1.default.writeFileSync(`${outputDir}/${item.id}.info.mdx`, utils, "utf8")
|
|
284
|
+
: fs_1.default.writeFileSync(`${outputDir}/${item.id}.info.mdx`, view, "utf8");
|
|
283
285
|
console.log(chalk_1.default.green(`Successfully created "${outputDir}/${item.id}.info.mdx"`));
|
|
284
286
|
}
|
|
285
287
|
catch (err) {
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "docusaurus-plugin-openapi-docs",
|
|
3
3
|
"description": "OpenAPI plugin for Docusaurus.",
|
|
4
|
-
"version": "0.0.0-
|
|
4
|
+
"version": "0.0.0-1001",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"keywords": [
|
|
7
7
|
"openapi",
|
|
@@ -65,5 +65,5 @@
|
|
|
65
65
|
"engines": {
|
|
66
66
|
"node": ">=14"
|
|
67
67
|
},
|
|
68
|
-
"gitHead": "
|
|
68
|
+
"gitHead": "7d52705fd006bd8d72e5d14b78b065eb5f5d4d3e"
|
|
69
69
|
}
|
package/src/index.ts
CHANGED
|
@@ -383,11 +383,17 @@ custom_edit_url: null
|
|
|
383
383
|
if (item.type === "info") {
|
|
384
384
|
if (!fs.existsSync(`${outputDir}/${item.id}.info.mdx`)) {
|
|
385
385
|
try {
|
|
386
|
-
|
|
387
|
-
|
|
388
|
-
|
|
389
|
-
|
|
390
|
-
|
|
386
|
+
sidebarOptions?.categoryLinkSource === "info" || infoTemplate // Only use utils template if set to "info" or if infoTemplate is set
|
|
387
|
+
? fs.writeFileSync(
|
|
388
|
+
`${outputDir}/${item.id}.info.mdx`,
|
|
389
|
+
utils,
|
|
390
|
+
"utf8"
|
|
391
|
+
)
|
|
392
|
+
: fs.writeFileSync(
|
|
393
|
+
`${outputDir}/${item.id}.info.mdx`,
|
|
394
|
+
view,
|
|
395
|
+
"utf8"
|
|
396
|
+
);
|
|
391
397
|
console.log(
|
|
392
398
|
chalk.green(
|
|
393
399
|
`Successfully created "${outputDir}/${item.id}.info.mdx"`
|