Deprecated package
@ember-data/tracking is deprecated. Deprecated since 5.5: the Ember reactivity bindings it provided now come from @warp-drive/ember, so remove it and install that instead.
For an app still on these packages, see Legacy Package Setup.
Historically, this package configured WarpDrive to use EmberJS's reactivity system.
Migration Guide
To resolve this deprecation, follow these steps:
1. Remove @ember-data/tracking
- Remove
@ember-data/trackingfrom package.json (if usingember-datathis may not be present) - Remove the
@ember-data/trackingentry from thetypesarray in tsconfig.json, if present - If using
untracked, change to usinguntrackfrom@glimmer/validator
2. Add @warp-drive/ember
- Add
@warp-drive/emberto package.json - the version to install should match the version ofember-dataor@ember-data/store - Do NOT add
@warp-drive/emberto tsconfig.json - the types in this package install automatically, you can remove any entry for this if it is there - Add
import '@warp-drive/ember/install';to the top of yourapp.jsorapp.tsfile
3. Clear the deprecation
Once the above steps are complete, the deprecation can be silenced and the automatic fallback registration of reactivity from @ember-data/tracking can be removed by updating your WarpDrive Build Config in your ember-cli-build file. On current versions setConfig is exported from @warp-drive/core/build-config; @warp-drive/build-config is its older home and still works. Set compatWith to the most recent major.minor your app has fully resolved deprecations for, not to the 4.12 shown.
'use strict';
const EmberApp = require('ember-cli/lib/broccoli/ember-app');
const { compatBuild } = require('@embroider/compat');
module.exports = async function (defaults) {
const { setConfig } = await import('@warp-drive/build-config');
const { buildOnce } = await import('@embroider/vite');
const app = new EmberApp(defaults, {});
setConfig(app, __dirname, {
// this should be the most recent <major>.<minor> version for
// which all deprecations have been fully resolved
// and should be updated when that changes
compatWith: '4.12',
deprecations: {
// ... list individual deprecations that have been resolved here
DEPRECATE_TRACKING_PACKAGE: false
}
});
return compatBuild(app, buildOnce);
};