define(function () {
var config = {
baseUrl: '',
paths: {
curl: './support/curl/src/curl',
underscore : '../app/js/lo-dash/lodash',
"test-js": 'test'
},
packages : [
{name : 'postal', location : '../app/js/postal/lib', main : 'postal'},
],
pluginPath: 'curl/plugin'
};
curl(config, ['postal']).then(
function () {
setPageState('loaded');
// this should never get called by cram:
curl(['some/other/module']);
},
function () {
setPageState('failed');
}
);
// do something DOM-ish (this code should never execute during build!)
function setPageState (stateClass) {
var root = document.documentElement;
root.className = root.className.replace(/loading/, '')
+ ' ' + stateClass;
}
});