How to load external js script from URL in Node.js

I have a node.js server running on a VPS and I want to use a js script that is served from another server, something like:

http://example.com/api/js

How do I load this script and use it in my node.js file?

  • Common module in node.js and browser javascript
  • How to use google analytics from jade file
  • Difference between assigning to res and res.locals in node.js (Express)
  • Ember and Express: let Ember handle routes instead of Express?
  • How to deal with async. findOrCreate method for passport and mongoose
  • Node.js programming workflow - Tests, Code, Tests
  • Thanks!

    Node.js is the Best Javascript runtime in the world.