js current window location endpoint code example Example: javascript get url path window.location.pathname