- #1744 Fixed a gap in merging update (@larry-x-yu)
- #1749 Fix nested cache merging for projections (@hjdivad)
- David J. Hamilton (@hjdivad)
- @larry-x-yu
- #1711 Bump node to active (12 -> 14) (@hjdivad)
- dropped support for ember-data versions < 3.28.0
- per ember 4 deprecation array observers no longer supported on managed arrays
- #1737 Fixed a m3-store initialization issue (@larry-x-yu)
- #1726 Fix 'firstObject/lastObject' properties in Ember 4 with native proxies (@larry-x-yu)
#1733 Fix nested cache merging for projections (@hjdivad)- this fix was in 6.0.0-alpha.2 but is dropped from 6.0.0
- #1743 test array.0 explicitly (@hjdivad)
- #1732 cache eslint (@hjdivad)
- #1731 fix deprecations (@hjdivad)
- #1713 Reduce dependabot clutter (@hjdivad)
- #1708 Bump deps + fix deprecations (@hjdivad)
- #1692 Set ember edition to "octane" (@nlfurniss)
- David J. Hamilton (@hjdivad)
- @larry-x-yu
- Nathaniel Furniss (@nlfurniss)
- #1737 Fixed a m3-store initialization issue (@larry-x-yu)
- #1733 Fix nested cache merging for projections (@hjdivad)
- #1726 Fix 'firstObject/lastObject' properties in Ember 4 with native proxies (@larry-x-yu)
- #1732 cache eslint (@hjdivad)
- #1731 fix deprecations (@hjdivad)
- #1713 Reduce dependabot clutter (@hjdivad)
- David J. Hamilton (@hjdivad)
- @larry-x-yu
- #1708 Bump deps + fix deprecations (@hjdivad)
- #1692 Set ember edition to "octane" (@nlfurniss)
- David J. Hamilton (@hjdivad)
- Nathaniel Furniss (@nlfurniss)
- #1688 [ember 4] Add
for
andsince
in deprecate() to be ember 4 compat (@serinyoon) - #1667 Cancel prior CI jobs for the same PR/branch. (@rwjblue)
- #1664 Fixup CI Runs (@rwjblue)
- Robert Jackson (@rwjblue)
- @serinyoon
- #1633 Update Ember-Inspector Compatibility (@pete-the-pete)
- #1568 Don't deprecate setting symbols (@runspired)
- #1626 A test case to show how to use a symbol as an attribute name (@larry-x-yu)
- Chris Thoburn (@runspired)
- Ewan McDougall (@mrloop)
- Pete (@pete-the-pete)
- @larry-x-yu
- #1612 Fixed a bug caused by using '&&=' syntax (@larry-x-yu)
- #1601 Fix lazy nested model creation for newly written attributes (@larry-x-yu)
- David J. Hamilton (@hjdivad)
- @larry-x-yu
- #1534 [bugfix] ensure that errors can be updated when using useUnderlyingErrorsValue (@gabrielcsapo)
- David J. Hamilton (@hjdivad)
- Gabriel Csapo (@gabrielcsapo)
- Robert Jackson (@rwjblue)
- Igor Terzic (@igorT)
- Igor Terzic (@igorT)
- Igor Terzic (@igorT)
- #1299
Array.isArray(value)
should not be used with M3 Arrays and will be returningtrue
in the future.
With Ember Data versions 3.28.0
and above M3 Arrays can be used as native JS arrays other than in IE11 which doesn't support proxies. For example, instead of having to do m3Array.objectAt(0)
you can now do m3Array[0]
.
However, because M3 Arrays are now proxying JavaScript native arrays, the return value of Array.isArray(m3Array)
will change to now be true
,
so it is no longer safe to rely on Array.isArray
to distinguish between native and m3 arrays. If you need to detect an M3 Array we have now provided a utility method isM3Array
:
import isM3Array from 'ember-m3/utils/is-m3-array'
// To replicate old behavior of `Array.isArray(value)` you would need to do:
let isJSArray = Array.isArray(value) && !isM3Array(value)
- #1300 Do not emit array change events when app is being destroyed (@igorT)
- #1301 Sync projections and base model deleted state with CUSTOM_MODEL_CLASS (@igorT)
- #1238 Add array native access (@igorT)
- #1232 Add native property access for models (@igorT)
- #1315 Add IE testing and guard proxies when they are not present (@igorT)
- #1298 Do not needlessly access
isDirty
(@igorT) - #1299 Switch m3 array proxies to proxy [] insted of BaseRecordArray (@igorT)
- #1301 Sync projections and base model deleted state with CUSTOM_MODEL_CLASS (@igorT)
- #1295 Fix isDeleted rollbackAttributes for Custom Model Class (@igorT)
- #1241 fix: skip this.errors.remove if useUnderlyingErrorsValue (@spham92)
- #1243 Fix isError and adapterError with CUSTOM_MODEL_CLASSES (@igorT)
- #1240 Fix for projected models resolving in projected arrays, when CUSTOM_MODEL_CLASS is on (@igorT)
- #1248 Add 'for' and 'since' to nativeProperties deprecation (@igorT)
- #1249 Fix isSaving for embedded records when CUSTOM MODEL CLASS is on (@igorT)
- #1242 Fix isDirty for inflight records and set _topModel to the proxy value (@igorT)
- #1247 Don't trigger dot access deprecations when useNativeProperties hook isn't defined (@igorT)
- #1296 Convert state tests to use native property access (@igorT)
- #1251 Cleanup the invalid errors test (@igorT)
- #1238 Add nattive property access for arrays (@igorT)
- #1232 Add native property access for models (@igorT)
- #1241 fix: skip this.errors.remove if useUnderlyingErrorsValue (@spham92)
- #1243 Fix isError and adapterError with CUSTOM_MODEL_CLASSES (@igorT)
- #1240 Fix for projected models resolving in projected arrays, when CUSTOM_MODEL_CLASS is on (@igorT)
- #1249 Fix isSaving for embedded records when CUSTOM MODEL CLASS is on (@igorT)
- #1242 Fix isDirty for inflight records and set _topModel to the proxy value (@igorT)
- #1226 Fix array resolving for non references when CUSTOM_MODEL_CLASS is off (@igorT)
- #1169 Custom Model Classes: Ensure isDirty for embedded records doesn't recursively loop (@igorT)
- #1175 Custom Model Classs: Fix isLoading and isLoaded flags on model (@igorT)
- #1184 Use operator instead of property access for existence checks (@igorT)
- #1183 Avoid repeatedly looking up the schema type when resolving (@igorT)
- #1179 Make perfomance testing app more robust to slow tests (@igorT)
- #1172 Upgrade ember-lts versions to actual latest and latest-1 (@igorT)
- Igor Terzic (@igorT)
- Igor Terzic (@igorT)
- Steven Pham (@spham92)
Internal release - no user-visible changes
Internal release - no user-visible changes
- #1032 Adds support for native Proxy behind a canary feature flag (@pzuraq)
- #787 replace computeNestedModel and computeAttributeReference schema hooks with computeAttribute (@igorT)
- #1131 Ensure we do not add custom babel plugins multiple times (@rwjblue)
- #1121 Avoid invalid imports in production app tree (@rwjblue)
- #1099 Fix state notifications when CUSTOM_MODEL_CLASS is active (@runspired)
- #1005 Pass owner when creating M3DebugAdapter (@pzuraq)
- #817 temporary fix for stringifying models in the debug adapter (@betocantu93)
- #840 Replace
new Object(null)
withObject.create(null)
. (@rwjblue)
- #1091 Updated pinned yarn version (@hjdivad)
- #1047 Refactor warning capturing and testing. (@rwjblue)
- #822 Remove work around for Ember < 2.12 relying on
setOwner
enumerability (@rwjblue) - #789 and #793 TrackedArrays and ReferenceArrays are now unified as a ManagedArray (@igorT)
- Alberto Cantú Gómez (@betocantu93)
- Chris Garrett (@pzuraq)
- Chris Thoburn (@runspired)
- David J. Hamilton (@hjdivad)
- Igor Terzic (@igorT)
- Robert Jackson (@rwjblue)
- Steven Pham (@spham92)
- #1131 Ensure we do not add custom babel plugins multiple times (@rwjblue)
- #1121 Avoid invalid imports in production app tree (@rwjblue)
- #1099 Fix state notifications when CUSTOM_MODEL_CLASS is active (@runspired)
- #1041 Only execute callback once per key for eachAttribute (backport #1022) (@betocantu93)
- Alberto Cantú Gómez (@betocantu93)
- [#784](Add queryParams option for Store.queryURL) (backported via #980)
- (@2hu)
- Igor Terzic (@igorT)
- David J. Hamilton (@hjdivad)
Avoid checker.check
when project depends on ember-data for a performance gain
- Robert Jackson (@rwjblue)
- #760 fix: flag store reopen and extend store properly (@runspired)
Migrating
If your app or addon previously used extendStore
or directly applied the store mixin, you will need to migrate your app or addon to extend from the ember-m3 store.
before with extendStore
import { extendStore } from 'ember-m3/mixins/store';
import Store from '@ember-data/store';
class AppStore extends Store {}
extendStore(AppStore);
export default AppStore;
before with Mixin
import StoreMixin from 'ember-m3/mixins/store';
import Store from '@ember-data/store';
class AppStore extends Store.extend(StoreMixin) {}
export default AppStore;
after
import Store from 'ember-m3/services/store';
export default class AppStore extends Store {}
- #760 fix: flag store reopen and extend store properly (@runspired)
- Chris Thoburn (@runspired)
- David J. Hamilton (@hjdivad)
- #695 utilize ember-data's project trim (@hjdivad)
- #705 cleanup: BREAKING drop EmberData<3.16 support for 2.0 (@runspired)
- #693 Dropping support for < ember-data 3.12 (@hjdivad)
- #719 updates readme with tests/dummy example and fix dummy (@betocantu93)
- #655 Unpin
ember-source
version inpackage.json
(@rwjblue) - #656 Add ember-lts-3.16 ember-try scenario. (@rwjblue)
- Alberto Cantú Gómez (@betocantu93)
- Chris Thoburn (@runspired)
- David J. Hamilton (@hjdivad)
- Robert Jackson (@rwjblue)
- Stefan Penner (@stefanpenner)
- Igor Terzic (@igorT)
- #563 Drop node 8 & upgrade all dependencies (@stefanpenner)
- #573 Drop node 8, like everybody else (@hjdivad)
- #567 Drop direct dependencies on Ember Data (@hjdivad)
- #570 Re-export interop-debug-adapter in app as data-adapter (@SYU15)
- #544 Allow .toString to be called on record prototype (@SYU15)
- David J. Hamilton (@hjdivad)
- Sarah Yu (@SYU15)
- Stefan Penner (@stefanpenner)
- #478 feat: support @ember-data packages and trimming (@runspired)
- Chris Thoburn (@runspired)
- Igor Terzic (@igorT)
- #477 perf: instantiate errors lazily (@runspired)
- #490 Fix isDirty regression (@hjdivad)
- #472 fix: remove seen model types in debug-adapter when inspector is closed (@SYU15)
- #458 fix: don't overwrite existing babel plugins (@hjdivad)
- #485 dx: Fix ember data feature import (@hjdivad)
- #483 dx: Fix CUSTOM_MODEL_CLASS fallback (@hjdivad)
- #460 chore: cleanup deprecations (@runspired)
- #459 Fix canary feature imports (@igorT)
- Chris Thoburn (@runspired)
- David J. Hamilton (@hjdivad)
- Igor Terzic (@igorT)
- Sarah Yu (@SYU15)
- feat: Add support for Ember Data custom model classes (thanks @igort)
- feat: Add support for displaying models in ember inspector (thanks @syu15)
- feat: Add
meta
support inqueryURL
(thanks @2hu12) - feat: Add headers support in
queryURL
(thanks @pyuan) - fix: Fix
isDirty
when setting an attr to its previous value (thanks @2hu12) - feat: Various updates to maintain compatibility with Ember Data canary (thanks @runspired)
- fix: Do not cause build errors with ember-cli-babel@7 (#386 thanks @rwjblue)
- docs: Improved debugging docs (thanks @syu15)
- feat:
adapter.queryURL
now supportsadapterOptions
(thanks @loganrosen)
- fix: model now dirties during set if the schema dirties any attribute (including ones other than what was set) #377 (thanks @rwjblue)
- feat: add debug-adapter for Ember-Inspector support (thanks @syu15)
- fix: fix
debugJSON
for projections (thanks @syu15) - fix: trigger change notifications when updating references in reference arrays (thanks @runspired)
- fix: trigger array change with correct index arg (thanks @rwjblue)
- fix: issues when creating record data for projections (thanks @runspired)
- fix: allow user schemas to compute references with null ids
- fix: user schema hooks take priority over raw values for determining reference arrays
- fix: compatibility with Ember Data 3.12.x (thanks @rwjblue)
- fix: only store base types in global cache (#315)
- chore: drop support for node 6 and ember 2.18 (we support latest 2 LTS and current release)
- feat: batch array changes. Array updates (eg from references updated in
store.push
) are now deferred along with regular property updates.
- fix: queryURL no longer erroneously caches rejected responses (thanks @teopalva)
- docs: update contributing guide (thanks @ghaagsma)
- fix: bring back M3TrackedArray.value and deprecate
- feat: allow handling of EmbeddedMegamorphicModels by computeNestedModel
- feat: dont stash value on tracked arrays
- feat: enable computeNestedModel to handle arrays
- bugfix: batch change notifications
- bugfix: setting arrays with a mix of models and pojos
- bugfix: Revert "Revert "Delegate
_destroyChildRecordData
to base""
- bugfix: Revert 'Delegate
_destroyChildRecordData
to base'
- bugfix: prevent cycles in dependencies from self-referential schemas (thanks @igort)
- bugfix: fix changed attributes for projections when dirty nested models set to null
- feature: Add
isAttributeResolved
API for schema control over interpreting set values as already resolved or not - bugfix: empty native arrays are now correctly treated as unresolved when set
- breaking:
changedAttributes
improved format for newly created nested records so they can be distinguished from edits to existing nested records (thanks @iterzic @eddie-ruva) - cleanup: add assertion for attempts to save embedded m3 models directly (thanks @ghaagsma)
- bugfix:
changedAttributes
could stack overflow from incorrect deep copy cycle detection (#231)
- bugfix:
hasLocalAttr
was not taking into account the base record data when dealing with a projection record. (thanks @eddi-ruva)
- feature: add
deleteAttr
to schema interface (thanks @eddi-ruva) - bugfix: nested model updates from local updates with partial updates from server #215 thanks (@ygongdev)
- bugfix:
rollbackAttributes
for record data from projections (thanks @eddi-ruva)
- bugfix: reference array updates are now resolved lazily #205
- bugfix: destroying new records does not trigger API request
- cleanup: dropped use of deprecated
Ember.copy
- cleanup: fixed errors in README (thanks @ibraheem4)
- bugfix: do not throw when setting an id to its current value
- bugfix: add support for ember-data 3.5.x
- bugfix: reference arrays can update to undefined (treated as now empty)
- bugfix: keep nested model state in sync
- bugfix: add
changedAttributes()
to nested models - bugfix: projections iterate attributes from base (#165)
- rollback ember-cli-babel to v6
- no longer including useless default service in
app/services/-ember-m3
which mainly forced apps with in-repo addons to ensure they hadafter
specified
- apps now specify schemas via a service rather than global registration
- tracked arrays accept embedded models from other top models (although this is not recommended)
- bugfix: tracked arrays no longer overwrite existing entries (thanks @dnalagatla)
modelName
is now passed tocomputeAttributes
- bugfix: dependent keys are tracked even when they are initially absent in the server payload
- breaking: schema manager is now a service. See UPGRADING.md. (thanks @dnachev)
- bugfix: fix support for ember 3.4.0-beta.1
- feature: Added cacheURL (thanks @sangm)
- records added to tracked arrays now remove themselves when unloaded
- Added support to track changes in Array #136
- models added to record arrays are now entangled with those arrays, so they'll be auto-removed when eg destroyed. Previously only models that started in record arrays were entangled.
- Fixed
computeNestedModel
schema hook to be able to callschemaInterface.getAttr()
- Added
setAttribute
schema hook #127
- Fixed updating state of model to
loaded.update.uncommitted
upon invokingset
in model.
- Fixed changedAttributes() on a projection to return all changes.
- Fixed handling of model names normalization. The schema no longer needs to normalize when returning references, nested models and base model names.
- Model supports client validation errors. For convenience with migrating from @ember-data/model,
errors
an instance of sameErrors
class used by@ember-data/model
, which provides list of vaidation errors.
- bugfix:
setUnknownProperty
remove cache and child model data if value is not resolved.
- bugfix:
setUnknownProperty
remove cache after setting a new value and only update cache when value is resolved.
- bugfix:
setUnknownProperty
only update cache when value is resolved.
- bugfix: Now able to get
length
ofM3RecordArray
as property.
-
breaking: Properties manually set, including those set in initial record creation, are treated as resolved. This means that
createRecord({ myprop })
will not use transforms formyprop
. -
bugfix: now able to set
RecordArray
properties withRecordArray
values. Semantics are still update in-place, as when setting to arrays of models.
-
breaking: To be consistent with the request types used in ember-data,
queryURL
will pass arequestType
ofqueryURL
. Previouslyquery-url
was passed. -
breaking: All arrays of references are now returned as
RecordArray
s.schema.isAttributeArrayRef
is therefore deprecated. -
store.queryURL
will now calladapter.queryURL
if it exists, instead ofadapter.ajax
. This is intended to be a hook for doing app-wide url conversion forstore.queryURL
calls beyond prepending the adapter namespace.
- bugfix: when using
schemaInterface
to compute attribute references from data other thankey
, dependencies are now tracked andkey
is invalidated correctly when those dependencies are invalidated. (thanks @dnalagatla)
- bugfix: prevent
notifyProperties(undefined)
from nested models with no changed attributes (thanks @sangm) - nested models that specify type, id are not re-used when these change.
null
id is fine for indicating a uniform type that should always be reused when new properties come in (thanks @dnachev) - attribute semantics now merge (so missing attributes are not treated as deletes thanks @dnachev)
- fix phantomjs regression (use of native Map).
- calls to
queryURL
for the samecacheKey
are now batched (thanks @dnalagatla)
-
fix ember 3.1 regression from unusual CP definition
-
fix regression from 0.4.0:
eachAttribute
iterates over modified attributes, as well as the last known attributes from the server. -
deleted models removed from record arrays
-
change to use ModelData. This is based on the implementation of the ModelData RFC and so is "pre-canary". This release should therefore be considered unstable. 0.5.x will likely depend on a version of Ember Data in which ModelData is the intimate addon API.
-
M3 models now report changed attributes via
changedAttributes
, like Ember Data.changedAttributes
reports changed attributes recursively for nested models.
- schema APIs now have access to the full data hash. This enables schemas that
depend on key mutations. For example,
computeAttributeReference
might work based on a key prefix{ '*book': '123' }
that differs from the property name (in this example,book
). Thanks @dnalagatla
- setting
id
now only asserts for top-level models, and not embedded models
model.reload
now supports passing{ adapterOptions }
- setting
id
for an existing model now asserts
- Nested model's
unloadRecord
now no-ops and warns instead of erroring