-
Notifications
You must be signed in to change notification settings - Fork 77
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Remove array, object, and storage mixins and helpers/utils
- Loading branch information
Showing
10 changed files
with
57 additions
and
43 deletions.
There are no files selected for viewing
2 changes: 1 addition & 1 deletion
2
addon/mixins/storage.js → addon/-private/legacy-mixins/storage.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,17 @@ | ||
import { A } from '@ember/array'; | ||
import ArrayProxy from '@ember/array/proxy'; | ||
import ArrayProxyMixin from '../mixins/array'; | ||
import { set } from '@ember/object'; | ||
import StorageProxyMixin from 'ember-local-storage/-private/legacy-mixins/storage'; | ||
import { save } from 'ember-local-storage/-private/legacy-utils'; | ||
|
||
export default ArrayProxy.extend(ArrayProxyMixin, { | ||
export default ArrayProxy.extend(StorageProxyMixin, { | ||
_initialContent: A(), | ||
_storageType: 'local', | ||
|
||
_clear() { | ||
set(this, 'content', A()); | ||
}, | ||
|
||
replaceContent: save, | ||
reset: save, | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,17 @@ | ||
import { set } from '@ember/object'; | ||
import ObjectProxy from '@ember/object/proxy'; | ||
import ObjectProxyMixin from '../mixins/object'; | ||
import StorageProxyMixin from 'ember-local-storage/-private/legacy-mixins/storage'; | ||
import { save, saveIfChanged } from 'ember-local-storage/-private/legacy-utils'; | ||
|
||
export default ObjectProxy.extend(ObjectProxyMixin, { | ||
export default ObjectProxy.extend(StorageProxyMixin, { | ||
_initialContent: {}, | ||
_storageType: 'local', | ||
|
||
_clear() { | ||
set(this, 'content', {}); | ||
}, | ||
|
||
setUnknownProperty: saveIfChanged, | ||
set: saveIfChanged, | ||
setProperties: save, | ||
}); |
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,17 @@ | ||
import { A } from '@ember/array'; | ||
import ArrayProxy from '@ember/array/proxy'; | ||
import ArrayProxyMixin from '../mixins/array'; | ||
import { set } from '@ember/object'; | ||
import StorageProxyMixin from 'ember-local-storage/-private/legacy-mixins/storage'; | ||
import { save } from 'ember-local-storage/-private/legacy-utils'; | ||
|
||
export default ArrayProxy.extend(ArrayProxyMixin, { | ||
export default ArrayProxy.extend(StorageProxyMixin, { | ||
_initialContent: A(), | ||
_storageType: 'session', | ||
|
||
_clear() { | ||
set(this, 'content', A()); | ||
}, | ||
|
||
replaceContent: save, | ||
reset: save, | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,17 @@ | ||
import { set } from '@ember/object'; | ||
import ObjectProxy from '@ember/object/proxy'; | ||
import ObjectProxyMixin from '../mixins/object'; | ||
import StorageProxyMixin from 'ember-local-storage/-private/legacy-mixins/storage'; | ||
import { save, saveIfChanged } from 'ember-local-storage/-private/legacy-utils'; | ||
|
||
export default ObjectProxy.extend(ObjectProxyMixin, { | ||
export default ObjectProxy.extend(StorageProxyMixin, { | ||
_initialContent: {}, | ||
_storageType: 'session', | ||
|
||
_clear() { | ||
set(this, 'content', {}); | ||
}, | ||
|
||
setUnknownProperty: saveIfChanged, | ||
set: saveIfChanged, | ||
setProperties: save, | ||
}); |