103 次浏览
使用 ember-localstorage 适配器。App.store = DS.Store.create({ revision: 11, adapter: DS.LSAdapter.create() });示例您需要定义打算用于客户端存储的适配器 - App.Store = DS.SyncStore.extend({ revision: 10, adapter: DS.IndexedDB.adapter({ mappings: { person: App.Person, persons: App.Person, contact: App.Contact, contacts: App.Contact } }) });