Refactor code structure for improved readability and maintainability

This commit is contained in:
2026-02-14 01:44:08 +08:00
parent 7865b64832
commit c08a471f6b
9 changed files with 4118 additions and 308 deletions

2781
react/package-lock.json generated Normal file

File diff suppressed because it is too large Load Diff

View File

@@ -11,14 +11,14 @@
"keywords": [],
"author": "abearxiong <xiongxiao@xiongxiao.me> (https://www.xiongxiao.me)",
"license": "MIT",
"packageManager": "pnpm@10.6.5",
"packageManager": "pnpm@10.29.3",
"type": "module",
"peerDependencies": {
"react": "^19.0.0"
},
"devDependencies": {
"@vitejs/plugin-react": "^4.3.4",
"vite": "^6.2.3",
"vite-plugin-dts": "^4.5.3"
"@vitejs/plugin-react": "^5.1.4",
"vite": "^7.3.1",
"vite-plugin-dts": "^4.5.4"
}
}

View File

@@ -1,7 +1,7 @@
import { createContext, useContext, useEffect, useMemo, useState } from 'react';
import { StateCreator } from '../../src/store';
import { shallow, useShallow } from 'zustand/shallow';
import { useContextKey } from '../../src/web-context';
import { useContextKey } from '../../src/web-env';
import { UseBoundStore, StoreApi } from 'zustand';
export const StoreContext = createContext<any>(null);

View File

@@ -1,7 +1,7 @@
import { createContext, useContext, useEffect, useMemo, useState } from 'react';
import { StateCreator } from '../../src/store';
import { shallow, useShallow } from 'zustand/shallow';
import { useContextKey } from '../../src/web-context';
import { useContextKey } from '../../src/web-env';
export const initStoreFn: StateCreator<any, [], [], any> = (set, get, store) => {
return {