Skip to content

Commit

Permalink
Merge pull request #1086 from samchon/feat/editor
Browse files Browse the repository at this point in the history
Fix editor page download bug
  • Loading branch information
samchon authored Oct 28, 2024
2 parents ffa983b + ba3bf17 commit dfc28c2
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 5 deletions.
5 changes: 3 additions & 2 deletions website/build/editor.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ const PACKAGE = `${__dirname}/../../packages/editor`;
const ASSETS = `${PACKAGE}/dist/assets`;

const main = async () => {
cp.execSync("npm install && npm run build:static", {
cp.execSync("npm i && npm run build:static", {
stdio: "ignore",
cwd: PACKAGE,
});
Expand All @@ -19,8 +19,9 @@ const main = async () => {
zip.file(`assets/${file}`, await fs.promises.readFile(`${ASSETS}/${file}`));
const buffer = await zip.generateAsync({
type: "uint8array",
compression: "DEFLATE",
compressionOptions: {
level: 0,
level: 9,
},
});
try {
Expand Down
4 changes: 2 additions & 2 deletions website/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
"description": "Nestia Guide Documents",
"private": true,
"scripts": {
"build": "rimraf .next && rimraf .out && node build/typedoc && next build && node build/sitemap",
"build": "rimraf .next && rimraf .out && node build/editor && node build/typedoc && next build && node build/sitemap",
"deploy": "node build/deploy",
"dev": "next dev"
},
Expand All @@ -23,7 +23,7 @@
"@mui/icons-material": "5.15.6",
"@mui/material": "5.15.6",
"@mui/system": "5.15.6",
"@nestia/editor": "0.3.0",
"@nestia/editor": "0.3.1",
"jszip": "^3.10.1",
"next": "14.2.13",
"nextra": "^2.13.4",
Expand Down
2 changes: 1 addition & 1 deletion website/pages/docs/editor.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ Install `@nestia/editor` and import one of below components.

> [💾 https://nestia.io/downloads/editor.zip](/downloads/editor.zip)
Just unzip the above [`editor.zip`]((/downloads/editor.zip)) file, and place your `swagger.json` file into the extracted directory.
Just unzip the above [`editor.zip`](/downloads/editor.zip) file, and place your `swagger.json` file into the extracted directory.

If you open the extracted `index.html` in your browser, you can see the `@nestia/editor` is serving the "TypeScript Swagger Editor" application with your `swagger.json` file.

Expand Down

0 comments on commit dfc28c2

Please sign in to comment.