A problem we have is that dat-gateway can serve dat archives via HTTP, but it cannot set the value of window.location. So any apps that rely on self-modification won't be able to use new DatArchive(window.location.href).
This could be addressed within dat-archive-web. It can detect when it receives an http(s) URL in its constructor, and will attempt to first, find the subdomain and check if it's a redirected archive (in which case it will do a base32 decode). Next it will try to get the domain or host from the first item in the path. If the second one fails, it'll just error out normally.
A problem we have is that dat-gateway can serve dat archives via HTTP, but it cannot set the value of
window.location
. So any apps that rely on self-modification won't be able to usenew DatArchive(window.location.href)
.This could be addressed within dat-archive-web. It can detect when it receives an
http(s)
URL in its constructor, and will attempt to first, find the subdomain and check if it's a redirected archive (in which case it will do a base32 decode). Next it will try to get the domain or host from the first item in the path. If the second one fails, it'll just error out normally.