import { PropsWithChildren } from 'react' import { useLaunch } from '@tarojs/taro' import { RecoilRoot } from 'recoil' import './styles/tailwind.basic.css' import { getGlobalConfig } from './apis' function App({ children }: PropsWithChildren) { useLaunch(() => { // 初始化全局配置 loadGlobalConfig() console.log('App launched.') }) const loadGlobalConfig = async () => { const res = await getGlobalConfig() console.log(res) } return ( {children} ) } export default App