首页IT科技vue路由点击没反应(vue 路由报错)

vue路由点击没反应(vue 路由报错)

时间2025-06-14 22:33:47分类IT科技浏览5741
导读:在进行如下路由跳转时...

在进行如下路由跳转时

const edit = (index: number) => {

let row: any = categoryData.value[index];

router.push({ name: “commodityedit              ”, query: { id: row.id, name: row.name } });

};

遇到问题如下

TypeError: Failed to fetch dynamically imported module: http://localhost:4000/src/views/product/commodityedit.vue

triggerError @ vue-router.esm-bundler.js:3325

(匿名) @ vue-router.esm-bundler.js:3057

Promise.catch(异步)

pushWithRedirect @ vue-router.esm-bundler.js:3051

push @ vue-router.esm-bundler.js:2986

install @ vue-router.esm-bundler.js:3403

use @ runtime-core.esm-bundler.js:4327

(匿名) @ main.ts:19

vue-router.esm-bundler.js:72 [Vue Router warn]: Unexpected error when starting the router: TypeError: Failed to fetch dynamically imported module: http://localhost:4000/src/views/product/commodityedit.vue

warn @ vue-router.esm-bundler.js:72

(匿名) @ vue-router.esm-bundler.js:3405

Promise.catch(异步)

install @ vue-router.esm-bundler.js:3403

use @ runtime-core.esm-bundler.js:4327

(匿名) @ main.ts:19

client.ts:53 [vite] connected.

Uncaught (in promise) TypeError: Failed to fetch dynamically imported module: http://192.xxx.xxx.xx:4000/src/views/orderManage/TradeOrder/TradeOrder.vue

原因:有可能是路由文件名打错了 或者文件位置不对

创心域SEO版权声明:以上内容作者已申请原创保护,未经允许不得转载,侵权必究!授权事宜、对本内容有异议或投诉,敬请联系网站管理员,我们将尽快回复您,谢谢合作!

展开全文READ MORE
cpanel怎么用(如何在cPanel中使用Webmail邮件系统?) linux mint换源(Linux换源)