Traveling Salesman Problem - With Conditions
Whether you need to find the optimal route regardless of conditions or you have conditions based on time windows and load capacity, tsp-wc will help you find the shortest route.
stops: ITspStop (required) initialTime: Date (optional) initialLoad: number (optional) - initial load capacity, generally set to 100 ignoreConditions: boolean (optional) - this will ignore conditions passed into stops initialPath:  (optional, not recommended to change)
ITspStop is defined as follows:
See tests/demo.html to learn more about how to incorporate this into your project via HTML and JS or tests/usage.ts for an example on how to tspwc with NodeJS and TypeScript. We have included a browser-friendly version of tspwc that you can find here. Please note that you will need your own Google API key to test this with both Maps and Directions API enabled on your Google Account.
In the project directory, you can run:
npm run build
npm run test-usage
Runs the sample usage.js file which should output a log in your console.
You can learn more about the developer here.