语法
语法
import { useUpdate } from "ahooks";
function App() {
const update = useUpdate();
console.log("哈哈");
return (
<div>
<h3>useUpdate</h3>
<button onClick={update}>刷新</button>
</div>
);
}
export default App;
import { useUpdate } from "ahooks";
function App() {
const update = useUpdate();
console.log("哈哈");
return (
<div>
<h3>useUpdate</h3>
<button onClick={update}>刷新</button>
</div>
);
}
export default App;