Skip to content
maranomynet edited this page Sep 13, 2010 · 5 revisions

Req.js – javascript lazy-loading and dependency managment made easy

Req.js is a simple, easy to use, full-featured library to handle lazy-loading and dependency management of Javascript.
It’s a standalone javascript library (no dependencies) and defines only a single object `Req` in the global scope.

Key Features:

  • Loads scripts asynchronously, with callbacks …
  • Ensuring all scripts execute in the correct order.
  • Resolves and loads script dependencies.
  • Handles circular dependencies gracefully.
  • Avoids loading the same script twice.
  • Supports custom checks for the pre-presence of each script asset.
  • Allows mixing of local and remotely-hosted scripts.
  • Supports nested calls.
  • Allows for joining multiple assets into one “combo” HTTP request. (if supported by your server)

Also:

  • Highly configurable.
  • Cross-browser and no external dependencies.
  • Fast (no evals)
  • Tiny! (less than 1 kB gzipped)

Downloads & Links

Copyright & Licensing

Copyright © 2009 Már Örlygsson and Hugsmiðjan ehf .

Dual licensed under a MIT license and GPL 2.0 (or above).