protocol

abstract override var protocol: String

URL: protocol

From MDN: "The protocol property of the URL interface is a string representing the protocol scheme of the URL, including the final ':'."

 

Notes & further reading

Example value:

const url = new URL("https://elide.dev/?one=two#hello");
url.protocol;
← "https:"

Note: This property is present on a mutable version of the URL interface.