Angular Url Parser

Start parsing your url in the simpliest way

View on github

Url examples

Current url : {{ Demo.example.current }}
{{ Demo.example.ex1 }}
{{ Demo.example.ex2 }}
{{ Demo.example.ex3 }}
{{ Demo.example.ex4 }}
{{ Demo.example.ex5 }}

API

urlParser.getProtocol( {{ Demo.selectedUrl }} )
{{ Demo.protocol | json }}
urlParser.getHost( {{ Demo.selectedUrl }} )
{{ Demo.host | json }}
urlParser.getHostname( {{ Demo.selectedUrl }} )
{{ Demo.hostname | json }}
urlParser.getPort( {{ Demo.selectedUrl }} )
{{ Demo.port | json }}
urlParser.getRoute( {{ Demo.selectedUrl }} )
{{ Demo.route | json }}
urlParser.getRouteAttributes( {{ Demo.selectedUrl }} )
{{ Demo.routeAttributes | json }}
urlParser.getQuerystring( {{ Demo.selectedUrl }} )
{{ Demo.queryString | json }}
urlParser.getOption( {{ Demo.selectedUrl }} )
{{ Demo.option | json }}
urlParser.getHash( {{ Demo.selectedUrl }} )
{{ Demo.hash | json }}