UNPKG

500 BJavaScriptView Raw
1/*
2 Configures a registry for use with an Ember-Data
3 store.
4
5 @method initializeStoreService
6 @param {Ember.ApplicationInstance | Ember.EngineInstance} instance
7*/
8export default function initializeStoreService(instance) {
9 // instance.lookup supports Ember 2.1 and higher
10 // instance.container supports Ember 1.11 - 2.0
11 const container = instance.lookup ? instance : instance.container;
12
13 // Eagerly generate the store so defaultStore is populated.
14 container.lookup('service:store');
15}