React Router2 useLocation 1. 소개 useLocation은 React Router에서 제공하는 hook으로 현재 페이지의 URL 정보를 가져올 때 많이 쓰인다. useLocation v6.22.0 | React Router useLocation Type declarationdeclare function useLocation(): Location; interface Location extends Path { state: State; key: string; } interface Path { pathname: string; search: string; hash: string; } This hook returns the current location object. This can reactrouter.com 2. 꿀팁 import * .. 2024. 2. 7. 소개 React Router는 SPA 방식에서 URL에 따라 페이지를 렌더링 해주는 라이브러리다. Feature Overview v6.21.3 | React Router Feature Overview Client Side Routing React Router enables "client side routing". In traditional websites, the browser requests a document from a web server, downloads and evaluates CSS and JavaScript assets, and renders the HTML sent from the server. When reactrouter.com 설치 npm install react-router-dom ya.. 2024. 1. 31. 이전 1 다음