vue3项目嵌入到iframe 页面刷新报404问题
刷新报404问题主要是 路由模式是histioy , 要改为hash 模式
import { createWebHistory, createWebHashHistory,createRouter, RouteRecordRaw } from 'vue-router';
路由配置文件由 createWebHistory 改为 createWebHashHistory
const router = createRouter({
history: createWebHashHistory(),
routes,
});
获取携带的参数
const str= window.location.search||window.location.hash

浙公网安备 33010602011771号