URLs
🌱 This post is in the growth phase. It may still be useful as it grows up.
URL strings and URL objects
# [URL strings and URL objects](https://nodejs.org/api/url.html#url-strings-and-url-objects)┌────────────────────────────────────────────────────────────────────────────────────────────────┐│ href │├──────────┬──┬─────────────────────┬────────────────────────┬───────────────────────────┬───────┤│ protocol │ │ auth │ host │ path │ hash ││ │ │ ├─────────────────┬──────┼──────────┬────────────────┤ ││ │ │ │ hostname │ port │ pathname │ search │ ││ │ │ │ │ │ ├─┬──────────────┤ ││ │ │ │ │ │ │ │ query │ │" https: // user : pass @ sub.example.com : 8080 /p/a/t/h ? query=string #hash "│ │ │ │ │ hostname │ port │ │ │ ││ │ │ │ ├─────────────────┴──────┤ │ │ ││ protocol │ │ username │ password │ host │ │ │ │├──────────┴──┼──────────┴──────────┼────────────────────────┤ │ │ ││ origin │ │ origin │ pathname │ search │ hash │├─────────────┴─────────────────────┴────────────────────────┴──────────┴────────────────┴───────┤│ href │└────────────────────────────────────────────────────────────────────────────────────────────────┘