Skip to content

Commit

Permalink
perf: replace serve-static with sirv (#683)
Browse files Browse the repository at this point in the history
  • Loading branch information
chenjiahan authored Jan 8, 2025
1 parent 888ff3e commit 3df021f
Show file tree
Hide file tree
Showing 5 changed files with 13 additions and 56 deletions.
3 changes: 1 addition & 2 deletions packages/client/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -38,14 +38,13 @@
"@types/node": "^16",
"@types/react": "^18.3.18",
"@types/react-dom": "^18.3.5",
"@types/serve-static": "1.15.7",
"antd": "5.15.3",
"normalize.css": "8.0.1",
"react": "18.3.1",
"react-dom": "18.3.1",
"react-error-boundary": "^4.1.2",
"react-router-dom": "6.4.3",
"serve-static": "1.16.2",
"sirv": "2.0.4",
"typescript": "^5.2.2"
},
"publishConfig": {
Expand Down
2 changes: 1 addition & 1 deletion packages/client/rsbuild.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import { pluginTypeCheck } from '@rsbuild/plugin-type-check';
import { pluginNodePolyfill } from '@rsbuild/plugin-node-polyfill';
import type { Rspack, RsbuildConfig } from '@rsbuild/core';
import { pluginSass } from '@rsbuild/plugin-sass';
import serve from 'serve-static';
import serve from 'sirv';
import path from 'path';
import fs from 'fs';

Expand Down
3 changes: 1 addition & 2 deletions packages/sdk/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@
"json-cycle": "^1.5.0",
"lodash": "^4.17.21",
"open": "^8.4.2",
"serve-static": "1.16.2",
"sirv": "2.0.4",
"socket.io": "4.8.1",
"source-map": "^0.7.4",
"tapable": "2.2.1"
Expand All @@ -43,7 +43,6 @@
"@types/cors": "2.8.17",
"@types/lodash": "^4.17.14",
"@types/node": "^16",
"@types/serve-static": "1.15.7",
"tslib": "2.8.1",
"typescript": "^5.2.2"
},
Expand Down
2 changes: 1 addition & 1 deletion packages/sdk/src/sdk/server/index.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import { Common, SDK, Thirdparty, Client } from '@rsdoctor/types';
import { Server } from '@rsdoctor/utils/build';
import serve from 'serve-static';
import serve from 'sirv';
import { Bundle } from '@rsdoctor/utils/common';
import assert from 'assert';
import bodyParser from 'body-parser';
Expand Down
59 changes: 9 additions & 50 deletions pnpm-lock.yaml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit 3df021f

Please sign in to comment.