I'm getting this error when I browse my webapp for the first time (usually in a browser with disabled cache).     Error: Mismatched anonymous define() module: function (require) {   HTML:  <html>    .    .    .    <script src="//aj...
RequireJS seems to do something internally that caches required javascript files. If I make a change to one of the required files, I have to rename the file in order for the changes to be applied.    The common trick of appending a version number a...
Is there a way to define a module that "dynamically" load other modules in RequireJS? If yes, how the optimizer (r.js) understands how/when a module has to be included?   For example, let dynModules a module which defines name/path pairs:...
In my system, I have a number of "classes" loaded in the browser each a separate files during development, and concatenated together for production. As they are loaded, they initialize a property on a global object, here G, as in this examp...
Backbone.js documentation suggest loading bootstrapped models this way:   <script> var Accounts = new Backbone.Collection; Accounts.reset(<%= @accounts.to_json %>); var Projects = new Backbone.Collection; Projects.reset(<%= @projects...
I'm using requireJS to load scripts. It has this detail in the docs:     The path that is used for a module name should not include the .js   extension, since the path mapping could be for a directory.   In my app, I map all of my script files in...
I'm still new to ES6 and module loaders and I'm currently looking at combining a browserify setup with ES6. I was wondering if I would still need browserify/requirejs if I'm using ES6 modules. Seems like both allow you to define modules...
I am trying to use r.js to optimize my code but I keep running to this error:  Tracing dependencies for: init  Error: Load timeout for modules: backbone,jquerymobile   The command I am running is this:  $ java -classpath /Users/dixond/build-tools/rhi...
I am using the current stable release of both require.js and jQuery and I am currently including jQuery like this  requirejs.config({ paths: {     'jQuery': 'vendor/jquery', } });  require(['jQuery'], function(jQuery) {     lo...
My application use require.js, I have a random bug (happens 1 time for 50 reload) Require.js write in the console :      Failed to load resource: the server responded with a status of 404 (Not Found)    Indeed, require.js try to include jquery from a...

Tags

Recent Questions

Top Questions

Home Tags Terms of Service Privacy Policy DMCA Contact Us

©2020 All rights reserved.