zhengyiming
3 天以前 a69bf92c8907eb1fed227afb156ff0e1c5821c24
apps/bMiniApp/src/hooks/router.ts
@@ -1,6 +1,7 @@
import Taro from '@tarojs/taro';
import { TabBarPageRouter } from '@/constants';
import { useSystemStore } from '@/stores/modules/system';
import { httpLoggerRecord } from '@12333/utils';
export function useSwitchTab() {
  const systemStore = useSystemStore();
@@ -10,6 +11,10 @@
    console.log('index: ', index);
    systemStore.setTabIndex(index);
    Taro.switchTab(option);
    httpLoggerRecord.info({
      message: `[switchTab]`,
      args: [option, { index, TabBarPageRouter }],
    });
  };
  return switchTab;
}