I have a few modules installed, with requirejs, and i have a file:
define(['moment'], function(moment){
alert(moment());
});
this file is in :
And I am loading from: http://xx/usecase/yadayada
as follows:
require(["/js/usecase.js"], function (m){})
It fails because require.js try to loads moment from:
http://xx/usecase/jam/moment/moment.js
instead of:
http://xx/jam/moment/moment.js
how can i fix this?
thanks
Have a look at the baseUrl config option for RequireJS:
http://requirejs.org/docs/api.html#config-baseUrl