router: implement RelativeURLPath

We can use this for generating correct relative URLs in pages that
we serve (we'll use it initially in the generated SVGs for bundles).

Also add some copyright notices that were needed.
is there any reason to prefer this to `basePath[0] != '/'`?