¡@

Home 

javascript Programming Glossary: requirejs

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

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

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

to use RequireJS build profile r.js in a multi page project I am currently learning.. r.js in a multi page project I am currently learning RequireJS fundamentals and have some questions regarding a build profile.. questions regarding a build profile main files and use of RequireJS with multi page projects. My project's directory structure is..

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

How to define modules that contain a single &ldquo class&rdquo.. that B comes after A if B uses A. I am planning to use RequireJS as an implementation of CommonJS Modules AsynchronousDefinition..

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.. the declaration in whatever order you wanted but now using RequireJS this introduces a dependency which is here intentionally circular.. it work but I see this solution as inferior to not using RequireJS AMD as it requires me the developer to be aware of this newly..

Loading backbone and underscore using requirejs

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

underscore.js requirejs share improve this question RequireJS 2.X now organically addresses non AMD modules such as Backbone..

Prevent RequireJS from Caching Required Scripts

http://stackoverflow.com/questions/8315088/prevent-requirejs-from-caching-required-scripts

RequireJS from Caching Required Scripts RequireJS seems to do something.. RequireJS from Caching Required Scripts RequireJS seems to do something internally that caches required javascript.. looking for is a way to prevent this internal cacheing of RequireJS required scripts without having to rename my script files every..

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

instead of loading the actual dependencies. I am using requirejs and the code for my module looks something like this define.. can effectively unit test javascript unit testing mocking requirejs share improve this question So after reading this pos t.. reading this pos t I came up with a solution that use the requirejs config function to create a new context for your test where..

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

main files start with essentially the same config options requirejs.config paths 'jquery' 'http ajax.googleapis.com ajax libs jquery.. my app dir structure or my use of RequireJS javascript requirejs share improve this question First of all this is not a question.. glaringly wrong with my app dir structure or my use of requirejs I would not say that. On the other hand the structure is perhaps..

Require.js bug random Failed to load resource

http://stackoverflow.com/questions/17026036/require-js-bug-random-failed-to-load-resource

paginator 'lib paginator' Thank you javascript jquery requirejs share improve this question It seems you have another entry..

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

new employee.Employee John Smith javascript commonjs requirejs share improve this question The AMD proposal allows you..

How to handle circular dependencies with RequireJS/AMD?

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

for something it was not designed for javascript commonjs requirejs share improve this question This is indeed a restriction..

Using RequireJS, how do I pass in global objects or singletons around?

http://stackoverflow.com/questions/5608685/using-requirejs-how-do-i-pass-in-global-objects-or-singletons-around

loaded and just pass that one. javascript singleton requirejs share improve this question You would make that a module..

Loading backbone and underscore using requirejs

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

backbone and underscore using requirejs I'm trying to load backbone and underscore and jquery with.. I'm trying to load backbone and underscore and jquery with requirejs. With the latest versions of backbone and underscore it seems.. Tracing dependencies for main js home httpd aahardy requirejs r.js line 7619 exception from uncaught JavaScript throw Error..

Prevent RequireJS from Caching Required Scripts

http://stackoverflow.com/questions/8315088/prevent-requirejs-from-caching-required-scripts

param to the end of the filename does not work with requirejs script src jsfile.js v2 script What I am looking for is a way.. Apache see some of the answers below. javascript jquery requirejs share improve this question RequireJS can be configured.. for cache busting. From the RequireJS documentation http requirejs.org docs api.html#config urlArgs Extra query string arguments..

Ember.js and RequireJS

http://stackoverflow.com/questions/8776151/ember-js-and-requirejs

like LAB.js work better for Ember javascript ember.js requirejs share improve this question EDIT 2012 01 30 I pushed a more..

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

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

nice feature. javascript internationalization backbone.js requirejs share improve this question I have recently been through..

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

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

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

is gained with RequireJS AMD in JS How much faster is requireJS actually on a large website Has anyone done any tests on the..

Poll for resource available with RequireJS

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

case socket.io ever temporarily goes down I'd like to have requireJS poll for the resource a few times until it is available and..

BackboneJS with XML ajax

http://stackoverflow.com/questions/8419061/backbonejs-with-xml-ajax

So I was trying to create a backbone application using requireJS by following Thomas Davis's tutorial . How do I go create Backbone..

Interacting with require.js modules from the Firebug/Chrome console?

http://stackoverflow.com/questions/8458561/interacting-with-require-js-modules-from-the-firebug-chrome-console

someMethod methods.anotherMethod call anotherMethod Once requireJS loads up our data main we can access any modules that have already.. we can access any modules that have already been loaded by requireJS from the javascript console command line like so methods require.. command line like so methods require 'methodsModule' requireJS has module methodsModule stored methods.someMethod call someMethod..

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

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

very similar to the recommended way of using jquery with requireJS jquery plugins need jquery to be loaded much like backbone tastypie..

Is it a bad practice to use the requireJS module as a singleton?

http://stackoverflow.com/questions/9733201/is-it-a-bad-practice-to-use-the-requirejs-module-as-a-singleton

it a bad practice to use the requireJS module as a singleton I plan to use the following pattern to.. I plan to use the following pattern to make use of the requireJS based module to act as a singleton. Please notice that classA..

When to use Requirejs and when to use bundled javascript?

http://stackoverflow.com/questions/12232848/when-to-use-requirejs-and-when-to-use-bundled-javascript

to use Requirejs and when to use bundled javascript This may be a dumb question.. So at runtime there will be only one app.min.js file. Now Requirejs is used to load modules or files at runtime. So the question..

Requirejs domReady plugin vs Jquery $(document).ready()?

http://stackoverflow.com/questions/15332628/requirejs-domready-plugin-vs-jquery-document-ready

domReady plugin vs Jquery document .ready I am using requirejs.. and need to initialize something on dom ready. Now Requirejs provides domReady plugin http requirejs.org docs api.html#pageload.. query the DOM and manipulate DOM nodes in this function. Requirejs doesn't work differently domReady . via @Gert Sønderby You could..

Requirejs why and when to use shim config

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

why and when to use shim config i read the requirejs document..

document.createElement(“script”) synchronously

http://stackoverflow.com/questions/3248384/document-createelementscript-synchronously

advise looking into a more robust script loading tool like Requirejs . There are a lot of special cases to worry about. For really..

Ember.js and RequireJS

http://stackoverflow.com/questions/8776151/ember-js-and-requirejs

object I'm finding that it can really butt heads with Requirejs. Would something like LAB.js work better for Ember javascript..