Commit 0fbcbeaf authored by Kim, Subin's avatar Kim, Subin
Browse files

상단으로 이동

parent 011ac7cb
...@@ -20,8 +20,10 @@ function Admin() { ...@@ -20,8 +20,10 @@ function Admin() {
useEffect(() => { useEffect(() => {
if (search.word == '') { if (search.word == '') {
window.scrollTo(0,0)
getProductlist() getProductlist()
} else { } else {
window.scrollTo(0,0)
handleSearch() handleSearch()
} }
}, [currentPage]) }, [currentPage])
......
...@@ -34,6 +34,7 @@ function ProductsList({ match }) { ...@@ -34,6 +34,7 @@ function ProductsList({ match }) {
}, [mainCategory]) }, [mainCategory])
useEffect(() => { useEffect(() => {
window.scrollTo(0,0)
changePage() changePage()
}, [currentPage]) }, [currentPage])
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment