Edit in JSFiddle

// 해쉬뱅 ("#" 문자 뒤)
console.log(window.location.hash);
// 호스트(도메인) 이름(port 포함)
console.log(window.location.host);
// 호스트(도메인)  이름
console.log(window.location.hostname);
// 전체 URL
console.log(window.location.href);
// 상대 경로("/" 문자 뒤)
console.log(window.location.pathname);
// 포트번호
console.log(window.location.port);
// 프로토콜(http/https)
console.log(window.location.protocol);
// queryString("?" 문자 뒤)
console.log(window.location.search);