set rootPath on JS URLs to support subdir installs

[#24]