Files
dukang/apps/mini-user/src/app.tsx
T
jacy 5a2e8dfcf8
CI / verify (pull_request) Has been cancelled
fix(mini-user): dedupe Taro reactMeta so H5 useDidShow works
Vite was bundling plugin-framework-react runtime twice, so tab pages crashed with useContext is not a function on enter/switch.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-07-15 19:33:51 +08:00

20 lines
513 B
TypeScript

import './lib/text-encoding-polyfill';
import { PropsWithChildren } from 'react';
import WechatShareBootstrap from './components/WechatShareBootstrap';
import { patchTaroH5Hooks } from './lib/patch-taro-h5-hooks';
import './app.css';
// H5:在首屏 page hooks 执行前,把 Taro.useDidShow 等绑到与 createReactApp 同一份 runtime
patchTaroH5Hooks();
function App({ children }: PropsWithChildren) {
return (
<>
<WechatShareBootstrap />
{children}
</>
);
}
export default App;