I am in the process of setting up a web API and I want to provide support for various versions of the underlying library.
In essence, I would like to access it through: where x.y.z represents the version of the library I am utilizing.
Using npm for managing my libraries, I have noticed that I can only specify one version of the dependencies.
My initial thought was to download each version manually into subfolders within my service, but I prefer not to do so. Instead, I envision having a predetermined list of approved versions in my configuration file which can be loaded at start-up for future reference.
How can I effectively implement support for multiple versions within my JavaScript web service's API? I am also willing to explore alternative package managers aside from npm.