jrburke/requirejs — Issue #201: Mixed case issue with dependency names
Author: enunez
Created: 2012-03-06 04:15:32+00:00
State: open

So I'm using the Backbone.modelbinding.js plugin to add Knockout-like data binding support to Backbone. It supports backbone as an AMD module if it exists, and it's trying to load it with dependency name "backbone" (my own modules do too). I'm also using the localstorage module in amdjs Backbone, but it's loading the backbone library as "Backbone". If I leave it as is, it attempts to load scripts/Backbone.js.

So anyway, here's how I *attempted* to fix this:

require.config({
paths: {
'jquery': '//ajax.googleapis.com/ajax/libs/jquery/1.7.1/jquery.min',
'jquery-ui': '//ajax.googleapis.com/ajax/libs/jqueryui/1.8.17/jquery-ui.min',
'underscore': '../lib/amdjs/underscore/underscore-min',
'Backbone': '../lib/amdjs/backbone/backbone-min',
'backbone': '../lib/amdjs/backbone/backbone-min',
'backbone-localstorage': '../lib/amdjs/backbone/examples/backbone-localstorage',
'backbone-modelbinding': '../lib/backbone.modelbinding.min'
}
});

Basically, I have "Backbone" and "backbone" pointing to the same file. This eliminated the incorrect request for "scripts/Backbone.js", but then I got the error:
Load timeout for modules: Backbone http://requirejs.org/docs/errors.html#timeout

I've temporarily modified backbone-localstorage.js to use the dependency name "backbone" instead of "Backbone" until this is fixed.