AMD in Javascript

AMD stands for Asynchronous Module Definition. In a nutshell, it’s a format or a specification for writing javascript.

So, what is a Javascript module?

Its a reusable code which exports specific objects, making them available for other modules through dependency references to be used their programs.

These modules can be loaded asynchronously, if desired.  That means, there’s  a huge improvement in website performance as the files are only loaded when they are needed.  Also, it provides developers with the flexibility to define order in which module dependencies have to be loaded and load multiple javascript files during runtime.

AMD implementation is used by jQuery, Dojo, Firebug etc. There are various javascipt module loaders like RequireJS,  Browserify,  Webpack, SystemJS

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s