Why you should (almost) never use an absolute path to your APIs again
freecodecamp.org
Recent advances in web apps architecture show that a decoupled front-end provides more flexibility for development and operations. It When an app is developed with this architecture in mind, the front-end needs to communicate to the back-end via APIs, generally REST.