@rsdoctor/client 0.0.2-beta.1 → 0.0.2-beta.2
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 +6 -0
- package/config/constants.ts +1 -1
- package/dist/index.html +1 -1
- package/dist/resource/css/{index.0c35ee21.css → index.261ebd32.css} +1 -1
- package/dist/resource/js/222.61269654.js +2 -0
- package/dist/resource/js/222.61269654.js.LICENSE.txt +24 -0
- package/dist/resource/js/402.e1518c27.js +1 -0
- package/dist/resource/js/927.3d0c60f8.js +456 -0
- package/dist/resource/js/{35.b145fc87.js.LICENSE.txt → 927.3d0c60f8.js.LICENSE.txt} +7964 -7433
- package/dist/resource/js/async/258.e0f8722a.js +2 -0
- package/dist/resource/js/async/258.e0f8722a.js.LICENSE.txt +13 -0
- package/dist/resource/js/async/779.ce1dd842.js +2 -0
- package/dist/resource/js/async/779.ce1dd842.js.LICENSE.txt +1 -0
- package/dist/resource/js/async/952.34ca0751.js +2 -0
- package/dist/resource/js/async/952.34ca0751.js.LICENSE.txt +55 -0
- package/dist/resource/js/index.9dad6859.js +150 -0
- package/dist/resource/js/{index.9f88d7b3.js.LICENSE.txt → index.9dad6859.js.LICENSE.txt} +791 -765
- package/package.json +4 -4
- package/rsbuild.config.ts +4 -3
- package/src/App.tsx +1 -1
- package/src/index.tsx +1 -2
- package/src/router.tsx +5 -1
- package/dist/resource/image/rsdoctor.508e522f.cc5166b8.png +0 -0
- package/dist/resource/image/rsdoctor.cc5166b8.png +0 -0
- package/dist/resource/js/35.b145fc87.js +0 -456
- package/dist/resource/js/index.9f88d7b3.js +0 -150
- package/src/common/imgs/rsdoctor.png +0 -0
- /package/dist/resource/css/{35.cd185e57.css → 927.cd185e57.css} +0 -0
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@rsdoctor/client",
|
|
3
|
-
"version": "0.0.2-beta.
|
|
3
|
+
"version": "0.0.2-beta.2",
|
|
4
4
|
"main": "dist/index.html",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
@@ -34,8 +34,8 @@
|
|
|
34
34
|
"react-router-dom": "6.4.3",
|
|
35
35
|
"serve-static": "1.15.0",
|
|
36
36
|
"typescript": "^5.2.2",
|
|
37
|
-
"@rsdoctor/
|
|
38
|
-
"@rsdoctor/
|
|
37
|
+
"@rsdoctor/types": "0.0.2-beta.2",
|
|
38
|
+
"@rsdoctor/components": "0.0.2-beta.2"
|
|
39
39
|
},
|
|
40
40
|
"publishConfig": {
|
|
41
41
|
"access": "public",
|
|
@@ -43,7 +43,7 @@
|
|
|
43
43
|
},
|
|
44
44
|
"scripts": {
|
|
45
45
|
"dev": "rsbuild dev",
|
|
46
|
-
"start": "rsbuild
|
|
46
|
+
"start": "rsbuild build -w",
|
|
47
47
|
"build": "rsbuild build",
|
|
48
48
|
"build:analysis": "ENABLE_DEVTOOLS_PLUGIN=true DEVTOOLS_DEV=true rsbuild build",
|
|
49
49
|
"preview": "rsbuild preview"
|
package/rsbuild.config.ts
CHANGED
|
@@ -11,7 +11,7 @@ import {
|
|
|
11
11
|
DistPath,
|
|
12
12
|
PortForCLI,
|
|
13
13
|
PortForWeb,
|
|
14
|
-
|
|
14
|
+
WebpackRsdoctorDirPath,
|
|
15
15
|
WebpackStatsFilePath,
|
|
16
16
|
} from './config/constants';
|
|
17
17
|
|
|
@@ -66,6 +66,7 @@ export default defineConfig((env) => {
|
|
|
66
66
|
},
|
|
67
67
|
|
|
68
68
|
performance: {
|
|
69
|
+
buildCache: false,
|
|
69
70
|
chunkSplit: {
|
|
70
71
|
strategy: 'custom',
|
|
71
72
|
splitChunks: {
|
|
@@ -134,8 +135,8 @@ export default defineConfig((env) => {
|
|
|
134
135
|
historyApiFallback: true,
|
|
135
136
|
setupMiddlewares: [
|
|
136
137
|
(middlewares) => {
|
|
137
|
-
if (fs.existsSync(
|
|
138
|
-
const fn = serve(
|
|
138
|
+
if (fs.existsSync(WebpackRsdoctorDirPath)) {
|
|
139
|
+
const fn = serve(WebpackRsdoctorDirPath, {
|
|
139
140
|
index: false,
|
|
140
141
|
setHeaders(res) {
|
|
141
142
|
res.setHeader('Content-Type', 'text/plain; charset=utf-8');
|
package/src/App.tsx
CHANGED
|
@@ -16,7 +16,7 @@ const App: React.FC = (): React.ReactElement => {
|
|
|
16
16
|
|
|
17
17
|
const [state, setState] = useState<Constants.PageState>(PageState.Success);
|
|
18
18
|
const [viewMode, setViewMode] = useState<Config['viewMode']>({ ...defaultConfig.viewMode });
|
|
19
|
-
const [manifest, setManifest] = useState<Manifest.
|
|
19
|
+
const [manifest, setManifest] = useState<Manifest.RsdoctorManifest>();
|
|
20
20
|
const [theme, setTheme] = useState(defaultConfig.theme);
|
|
21
21
|
|
|
22
22
|
if (state === Constants.PageState.Fail) {
|
package/src/index.tsx
CHANGED
|
@@ -2,7 +2,6 @@ import '@rsdoctor/components/i18n';
|
|
|
2
2
|
import App from './App';
|
|
3
3
|
import ReactDOM from 'react-dom/client';
|
|
4
4
|
import './common/styles/base.scss';
|
|
5
|
-
import icon from './common/imgs/rsdoctor.png';
|
|
6
5
|
|
|
7
6
|
const rootElement = document.getElementById('root');
|
|
8
7
|
const root = ReactDOM.createRoot(rootElement!);
|
|
@@ -12,5 +11,5 @@ root.render(<App />);
|
|
|
12
11
|
const link = document.createElement('link');
|
|
13
12
|
link.setAttribute('type', 'image/x-icon');
|
|
14
13
|
link.setAttribute('rel', 'icon');
|
|
15
|
-
link.setAttribute('href',
|
|
14
|
+
link.setAttribute('href', 'https://lf3-static.bytednsdoc.com/obj/eden-cn/lognuvj/rsdoctor/logo/rsdoctor.png');
|
|
16
15
|
document.head.appendChild(link);
|
package/src/router.tsx
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { Route, Routes } from 'react-router-dom';
|
|
3
|
-
import { Overall, BundleSize, LoaderFiles, PluginsAnalyze, ModuleResolve, LoaderTimeline } from '@rsdoctor/components/pages';
|
|
3
|
+
import { Overall, BundleSize, LoaderFiles, PluginsAnalyze, ModuleResolve, LoaderTimeline, RuleIndex } from '@rsdoctor/components/pages';
|
|
4
4
|
|
|
5
5
|
|
|
6
6
|
export default function Router(): React.ReactElement {
|
|
@@ -29,6 +29,10 @@ export default function Router(): React.ReactElement {
|
|
|
29
29
|
path: LoaderTimeline.route,
|
|
30
30
|
element: <LoaderTimeline.Page />,
|
|
31
31
|
},
|
|
32
|
+
{
|
|
33
|
+
path: RuleIndex.route,
|
|
34
|
+
element: <RuleIndex.Page />,
|
|
35
|
+
},
|
|
32
36
|
].filter((e) => Boolean(e)) as { path: string; element: JSX.Element }[];
|
|
33
37
|
|
|
34
38
|
return (
|
|
Binary file
|
|
Binary file
|