hey there,
I really tried to use StackOverflow for my questions/problems related to Ember App Kit but it seems that either nobody who uses or knows Ember App Kit is present over there, or the people are not interested in giving answers/advices to those who need it
so, now I try my luck here - hope to get some feedback here
Until now, I used to develop my Ember project with the boilerplate which was given by @trek (https://github.com/trek/ember-todos-with-build-tools-tests-and-other-modern-conveniences) but now I want to migrate it into Ember App Kit. so far so good. I’ve got some util classes / objects which are now living within the App
namespace so that they’re accessible from all my other objects/controllers/routes/models/views/ etc.
window.App = Ember.Application.create({
LOG_TRANSITIONS: true,
LOG_TRANSITIONS_INTERNAL: true,
Resolver: Ember.DefaultResolver.extend({
resolveTemplate: function (parsedName) {
// some fancy stuff to get my templates from the server on demand...
}
}),
ready: function () {
Em.$('#initial-ajax-loader').remove();
}
});
App.creationTime = Date.now();
require('app/utils/utils');
require('app/controllers/controllers');
require('app/routes/router');
App.AjaxManager = App.utils.ajax.AjaxManager.create({creationTime: App.creationTime});
App.localStorageTimeout = 24 * 60 * 60000;
App.EventDispatcher = App.utils.event.EventDispatcher;
App.StorageLogger = App.utils.logging.StorageLogger.create({storageManager: App.utils.browser.storage.StorageManager.create({'prefix': 'app'})});
// ... some more util classes
require('app/helpers/helpers');
require('app/views/views');
require('app/models/models');
so, this is my code base now, but if I want to transfer this to EAK
I see troubles all the way and I have a few questions:
- how would I implement my application wide util classes/objects?
- is it still possible to have some properties within the
App
namespace so that this is available within controllers/routes/models/views etc. as before? - do I need to transfer the code into
Ember.Application.initializer
?