Today I Learned(23.02.04)

졍이🥨·2023년 2월 4일
0

개발일지

목록 보기
38/38

2023-02-04 (토)

특정 페이지에서만 Header와 Footer를 안보이게 하고 싶어서 구글링해봄!

Header와 Footer 컴포넌트에서

if (window.location.pathname === "/안보이게 하고싶은 주소") return null;

위 코드를 적어주면 된다 !

profile
Front-End :)

0개의 댓글