update path

This commit is contained in:
“李仕蓬”
2022-11-16 15:10:19 +08:00
parent 02a70f8de7
commit d5dd1f5a7d
2 changed files with 3 additions and 1 deletions

View File

@ -10,7 +10,7 @@ const root = ReactDOM.createRoot(
);
root.render(
<React.StrictMode>
<HashRouter basename="">
<HashRouter basename="/">
<App />
</HashRouter>
</React.StrictMode>

View File

@ -120,10 +120,12 @@ function CodeEditor() {
iframeRef.current?.contentWindow?.removeEventListener('mousemove', handleMouseMove);
iframeRef.current?.contentWindow?.removeEventListener('mouseup', handleMouseUp);
}
// eslint-disable-next-line react-hooks/exhaustive-deps
}, [iframeRef.current])
useEffect(() => {
getCode(url);
// eslint-disable-next-line react-hooks/exhaustive-deps
}, [url])
return (