javascript origin url
const originString = url.origin
Here is what the above code is Doing:
1. We’re using the url module to parse the URL.
2. We’re using the parse method to parse the URL.
3. We’re using the url.origin property to get the origin of the URL.