Skip to content

Instantly share code, notes, and snippets.

@johnpapa
Created June 18, 2012 03:41
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save johnpapa/2946723 to your computer and use it in GitHub Desktop.
Save johnpapa/2946723 to your computer and use it in GitHub Desktop.
partial main.js
requirejs([
// 3rd party libraries
'json2',
'jquery',
'underscore',
'moment',
'sammy',
'amplify',
'ko',
'toastr',
'bootstrapper',
// 3rd party plugins - they don't return modules
'activity-indicator', // jquery plugin
'sammy.title', // sammy plugin
'amplify.request', // amplify plugin
'amplify.store', // amplify plugin
'jquery.mockjson', // jquery plugin
'jquery.activity-ex', // jquery plugin
'ko.utils', // Knockout custom utilities
'ko.bindingHandlers', // Knockout custom binding handlers
'ko.bindingHandlers.activity', // Knockout custom binding handlers
'ko.bindingHandlers.command', // Knockout custom binding handlers
'ko.asyncCommand', // Knockout custom asyncCommand
'koExternalTemplateEngine',
'knockout.changetracker',
'debug.helpers' // our app's ko debugging plugin
], function (json2, $, _, moment, sammy, amplify, ko, toastr, bootstrapper,
activityIndicator, sammyTitle, amplifyRequest, amplifyStore,
jqueryMockJson, jqueryActivityEx, koUtils, koBindingHandlers,
koBindingHandlersActivity, koBindingHandlersCommand, koAsyncCommand,
koExternalTemplateEngine, knockoutChangeTracker, debugHelpers)
//WARD: no need for plugin params as they are always undefined
//PAPA: When I added the plugin parametes, I stopped getting load
// errors on some of the plugins (like koChangeTracker's ko.DirtyFlag)
{
//debugger; //TODO: uncomment to confirm that these dependencies are loaded.
// PAPA: Will this force all bootstrapper dedpendencies to load first? I hope so!
require('bootstrapper').run();
//bootstrapper.run();
})
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment