fix(web): 修复切换路由不刷新页面的问题

This commit is contained in:
v-zhangjc9
2025-05-09 11:27:16 +08:00
parent de445d7061
commit 8a7ad32df9

View File

@@ -1,5 +1,5 @@
import React from 'react' import React from 'react'
import {useParams} from 'react-router' import {useLocation, useParams} from 'react-router'
import { import {
amisRender, amisRender,
commonInfo, commonInfo,
@@ -11,8 +11,9 @@ import {
const Yarn: React.FC = () => { const Yarn: React.FC = () => {
const {clusters, queue, search} = useParams() const {clusters, queue, search} = useParams()
const location = useLocation()
return ( return (
<div className="hudi-yarn bg-white"> <div key={location.key} className="hudi-yarn bg-white">
{amisRender( {amisRender(
{ {
type: 'wrapper', type: 'wrapper',