This addon provides potential future ember-data APIs as experiments in ergonomics.
- You should play around with it, you probably shouldn't build a production app with it.
- You should create RFCs from the ideas or open issues with feedback, you probably shouldn't start refactoring your app with it.
- You should contribute tests, bugfixes, or additional concepts, you probably shouldn't copy paste any of this into your app.
The goal of this addon is to explore paths for
- eliminating
PromiseProxy
. - eliminating
ArrayProxy
. - unwrapping dual-purpose proxies (proxies that proxy to more than one source, for instance, how relationships and queries also have meta and links attached to their proxy).
- eliminating unnecessary proxies.
- providing access to more complete document and resource contents.
The paths MUST be capable of working with the world we have today, while unlocking the world we want to refactor to tomorrow.
ember install ember-data-experiments-mega-unstable
The helpers provide a consistent (never promise-proxy, always Record or RecordArray) experience regardless
of whether async
or non-async
relationships are in use. They will trigger loads of relationships that
have not been loaded yet.
Further iterations will provide mechanisms for
- queryParams and other request options
- preventing fetch (enforce local data only)
- loading state for documents
- errors, meta, and links for documents
- disallowing template based fetch (data must be already locally available)
fetch-data
fetch-document
... coming soon ...
... coming soon ...
git clone <repository-url>
cd ember-data-experiments-mega-unstable
npm install
npm run lint:js
npm run lint:js -- --fix
ember test
– Runs the test suite on the current Ember versionember test --server
– Runs the test suite in "watch mode"ember try:each
– Runs the test suite against multiple Ember versions
ember serve
- Visit the dummy application at http://localhost:4200.
For more information on using ember-cli, visit https://ember-cli.com/.
This project is licensed under the MIT License.