Parse URL in javascript for static site generator.