Closed jahamed closed 1 year ago
Using 'stripProtocol' to remove http/https but I would like to change audlindin.is/##.owl-stage-outer to audlindin.is
audlindin.is/##.owl-stage-outer
audlindin.is
Am I missing an option or is there an efficient way to do this?
Basically want to extract the domain name only if possible :)
You can use stripTextFragment: true too. But it's simpler to just do new URL(url).hostname.
stripTextFragment: true
new URL(url).hostname
Using 'stripProtocol' to remove http/https but I would like to change
audlindin.is/##.owl-stage-outer
toaudlindin.is
Am I missing an option or is there an efficient way to do this?
Basically want to extract the domain name only if possible :)