How do I remove a protocol / scheme from a URI?
Closed this issue · 1 comments
wsargent commented
I'd like to create a protocol relative URL from an absolute URL, but I don't see a way to do that from the documentation. Is this possible?
philwill-nap commented
Try this in the REPL:
import com.netaporter.uri._
val absoluteUri = Uri.parse("scheme://host/path")
val protocolRelativeUri = absoluteUri.copy(scheme=None)