¡@

Home 

javascript Programming Glossary: amd

How can I mock dependencies for unit testing in RequireJS?

http://stackoverflow.com/questions/11439540/how-can-i-mock-dependencies-for-unit-testing-in-requirejs

mock dependencies for unit testing in RequireJS I have an AMD module I want to test but I want to mock out its dependencies..

How to use RequireJS build profile + r.js in a multi-page project

http://stackoverflow.com/questions/11674824/how-to-use-requirejs-build-profile-r-js-in-a-multi-page-project

ended up with the following solution 1 Do not wrap the non AMD compliant files with a define. Although it works you can achieve.. section allows you to specify dependencies between non AMD compliant files. For example somejqueryplugin must be loaded..

supporting both CommonJS and AMD

http://stackoverflow.com/questions/13673346/supporting-both-commonjs-and-amd

both CommonJS and AMD Is there a way to create a javascript micro library a library..

RequireJS: How to define modules that contain a single “class”?

http://stackoverflow.com/questions/4869530/requirejs-how-to-define-modules-that-contain-a-single-class

commonjs requirejs share improve this question The AMD proposal allows you to just return a value for the exported.. for the exported object. But note that is a feature of the AMD proposal it is just an API proposal and will make it harder..

How to handle circular dependencies with RequireJS/AMD?

http://stackoverflow.com/questions/4881059/how-to-handle-circular-dependencies-with-requirejs-amd

to handle circular dependencies with RequireJS AMD In my system I have a number of classes loaded in the browser.. global object I am considering to make each class its own AMD module based on James Burke's suggestion define Employee Company.. but I see this solution as inferior to not using RequireJS AMD as it requires me the developer to be aware of this newly created..

How to structure my javascript/jquery code?

http://stackoverflow.com/questions/528648/how-to-structure-my-javascript-jquery-code

javascript jquery share improve this question AMDS It's been awhile since first answers got posted to this question.. foremost the JS browser world seems to be moving towards AMDs asynchronous module definition for code organization. The way.. The way that works is you write ALL your code as AMD modules e.g. define 'moduleName' 'dependancy1' 'dependancy2'..

Loading backbone and underscore using requirejs

http://stackoverflow.com/questions/8131265/loading-backbone-and-underscore-using-requirejs

underscore is available globally unless using synchronous AMDs it seems . I should also note that backbone doesn't seem to.. question RequireJS 2.X now organically addresses non AMD modules such as Backbone Underscore much better using the new.. of Backbone Underscore outweigh the benefits of using the AMD fork recommended in the other popular answer but either way..

JavaScript I18n (internationalization) frameworks/libraries for client-side use?

http://stackoverflow.com/questions/9640630/javascript-i18n-internationalization-frameworks-libraries-for-client-side-use

should not drive your decision. Even if the library is not AMD compliant you will wrap it and also find a way to async load..

How to load bootstrapped models in Backbone.js while using AMD (require.js)

http://stackoverflow.com/questions/9916073/how-to-load-bootstrapped-models-in-backbone-js-while-using-amd-require-js

to load bootstrapped models in Backbone.js while using AMD require.js Backbone.js documentation suggest loading bootstrapped.. true script But this is a pattern that can't be used in AMD approach using require.js The only possible solution is to declare..

Loading Highcharts via shim using RequireJS and maintaining jQuery dependency

http://stackoverflow.com/questions/10907519/loading-highcharts-via-shim-using-requirejs-and-maintaining-jquery-dependency

did by posting this. javascript highcharts requirejs js amd share improve this question I had the exact same problem..

How to achieve lazy loading with RequireJS?

http://stackoverflow.com/questions/10911044/how-to-achieve-lazy-loading-with-requirejs

you use this notation javascript backbone.js requirejs js amd share improve this question Is this actually possible Are..

How to make a jQuery plugin loadable with requirejs

http://stackoverflow.com/questions/10918063/how-to-make-a-jquery-plugin-loadable-with-requirejs

does which is like this if typeof define function define.amd define.amd.jQuery define jquery function return jQuery or if.. is like this if typeof define function define.amd define.amd.jQuery define jquery function return jQuery or if this is the.. to make jQuery plugins compatible with requirejs or any amd javascript jquery requirejs share improve this question ..

Expire cache on require.js data-main

http://stackoverflow.com/questions/11088909/expire-cache-on-require-js-data-main

script cache javascript caching requirejs browser cache amd share improve this question How are you defining your require.config..

How much speed is gained with RequireJS/AMD in JS?

http://stackoverflow.com/questions/11531091/how-much-speed-is-gained-with-requirejs-amd-in-js

the size. javascript performance asynchronous requirejs amd share improve this question I don't believe that the intent..

require.js: Access all loaded modules

http://stackoverflow.com/questions/11756483/require-js-access-all-loaded-modules

idea of how to accomplish that javascript requirejs js amd share improve this question Yes require.s.contexts._.defined..

supporting both CommonJS and AMD

http://stackoverflow.com/questions/13673346/supporting-both-commonjs-and-amd

exports as a global namespace object no loader javascript amd commonjs share improve this question Here is a list of various..

Backbone.js Memory Management, Rising DOM Node Count

http://stackoverflow.com/questions/15126334/backbone-js-memory-management-rising-dom-node-count

app is built on Backbone mv Zepto similar to jquery Curl amd loader Mustache templating . Problem I've just conquered the..

Requirejs why and when to use shim config

http://stackoverflow.com/questions/15471088/requirejs-why-and-when-to-use-shim-config

and when should we use shim. thanks. javascript requirejs amd share improve this question A primary use of shim is with..

Correct way to implement jQuery with require.js

http://stackoverflow.com/questions/15613577/correct-way-to-implement-jquery-with-require-js

work Any help is appreciated. javascript jquery requirejs amd share improve this question The key points as I see it jQuery.. for multiple jQuery versions by specifying define.amd.jQuery true. Register as a named module since jQuery can be.. of jQuery it will work. if typeof define function define.amd define.amd.jQuery define jquery function return jQuery UPDATE..

Poll for resource available with RequireJS

http://stackoverflow.com/questions/17599082/poll-for-resource-available-with-requirejs

setTimeout initialize 10000 javascript node.js requirejs amd socketio share improve this question I know this is an old..

RequireJS: Loading modules including templates and CSS

http://stackoverflow.com/questions/7917639/requirejs-loading-modules-including-templates-and-css

Good or bad javascript css requirejs javascript module js amd share improve this question You can specify the template..

Using non-AMD compatible javascript module with require.js?

http://stackoverflow.com/questions/8675874/using-non-amd-compatible-javascript-module-with-require-js

AMD compatible backbone tastypie called backbone tastypie amd. While sander's solution would work its a little annoying to.. define function factory if typeof define 'function' define.amd AMD. Register as an anonymous module. define 'backbone' factory..

Why did Underscore.js remove support for AMD?

http://stackoverflow.com/questions/9009510/why-did-underscore-js-remove-support-for-amd

supported again. javascript underscore.js requirejs js amd share improve this question Jeremy gave his reasoning in..

How to load bootstrapped models in Backbone.js while using AMD (require.js)

http://stackoverflow.com/questions/9916073/how-to-load-bootstrapped-models-in-backbone-js-while-using-amd-require-js

this without globals javascript backbone.js requirejs js amd share improve this question This is how we bootstrap data..