Javascript routing for websites

A little function that will return true or false depending id the current url is allowed. Simply pass it the paths of your domain it is allowed on and if the current url is allowed the function returns true.

Exmaple use for allowed paths, the init will run on these paths:

Exmaple use for not allowed paths, any other parth will run the init: