Skip to content

Commit 4f49bbb

Browse files
committed
docs: update overviews with recent library improvements
1 parent f1d4598 commit 4f49bbb

File tree

2 files changed

+90
-45
lines changed

2 files changed

+90
-45
lines changed

README.md

+4-4
Original file line numberDiff line numberDiff line change
@@ -32,11 +32,11 @@ WarpDrive provides features that make it easy to build scalable, fast, feature
3232
rich application — letting you ship better experiences more quickly without re-architecting your app or API. WarpDrive is:
3333

3434
- ⚡️ Committed to Best-In-Class Performance
35-
- 🌲 Focused on being as svelte as possible
36-
- 🚀 SSR Ready
3735
- 💚 Typed
38-
- 🔜 works with any framework
39-
- ⚛️ Supports any API: `GraphQL` `JSON:API` `REST` `tRPC` ...bespoke or a mix
36+
- ⚛️ Works with any API
37+
- 🌲 Focused on being as tiny as possible
38+
- 🚀 SSR Ready
39+
- 🔜 Seamless reactivity in any framework
4040
- 🐹 Built with ♥️ by [Ember](https://emberjs.com)
4141

4242
<br>

packages/-ember-data/README.md

+86-41
Original file line numberDiff line numberDiff line change
@@ -15,21 +15,35 @@
1515
/>
1616
</p>
1717

18-
<p align="center">The lightweight reactive data library for JavaScript applications</p>
18+
<p align="center">
19+
<br>
20+
<a href="https://warp-drive.io">EmberData</a> is a lightweight data library for web apps &mdash;
21+
<br>
22+
universal, typed, reactive, and ready to scale.
23+
<br/><br/>
24+
<p>
25+
26+
> [!TIP]
27+
> EmberData is going universal and rebranding as WarpDrive
28+
> with support for any signals based reactive framework!
29+
>
30+
> This means you may already see some references to WarpDrive.
1931
2032
[![Build Status](https://github.com/emberjs/data/workflows/CI/badge.svg)](https://github.com/emberjs/data/actions?workflow=CI)
2133
[![Discord Community Server](https://img.shields.io/discord/480462759797063690.svg?logo=discord)](https://discord.gg/zT3asNS)
2234

2335
---
2436

25-
Wrangle your application's data management with scalable patterns for developer productivity.
37+
EmberData provides features that make it easy to build scalable, fast, feature
38+
rich application &mdash; letting you ship better experiences more quickly without re-architecting your app or API. EmberData is:
2639

2740
- ⚡️ Committed to Best-In-Class Performance
28-
- 🌲 Focused on being as svelte as possible
41+
- 💚 Typed
42+
- ⚛️ Works with any API
43+
- 🌲 Focused on being as tiny as possible
2944
- 🚀 SSR Ready
30-
- 🔜 Typescript Support
45+
- 🔜 Seamless reactivity in any framework
3146
- 🐹 Built with ♥️ by [Ember](https://emberjs.com)
32-
- ⚛️ Supports any API: `GraphQL` `JSON:API` `REST` `tRPC` ...bespoke or a mix
3347

3448
**Tagged Releases**
3549

@@ -91,22 +105,29 @@ not wish to use `ember-data`, remove `ember-data` from your project's `package.j
91105

92106
## Advanced Installation
93107

94-
*Ember***Data** is organized into primitives that compose together via public APIs.
95-
96-
- [@ember-data/request](./packages/request) provides managed `fetch` via its RequestManager and can be used without any other parts of EmberData.
97-
- [@ember-data/store](./packages/store) is the "core" of EmberData and handles coordination between the RequestManager, the Cache, and Presentation Concerns.
98-
- [@ember-data/tracking](./packages/tracking) is currently required when using the core and provides tracking primitives for change notification of Tracked properties.
99-
- [@ember-data/json-api](./packages/json-api) is a resource cache for JSON:API structured data. It integrates with the store via the hook `createCache`
100-
- [@ember-data/model](./packages/model) is a presentation layer, it integrates with the store via the hooks `instantiateRecord` and `teardownRecord`.
101-
- [@ember-data/debug](./packages/debug) provides (optional) debugging support for the `ember-inspector`.
102-
108+
*Ember***Data** is organized into primitives that compose together via public APIs. These primitives are organized into
109+
small packages encapsulating these boundaries. These packages
110+
declare peer-dependencies (sometimes optional peer dependencies)
111+
on the other *Ember***Data**/*Warp***Drive** packages they require use of.
112+
113+
- [@ember-data/request](../packages/request) provides managed `fetch`
114+
- [@ember-data/request-utils](../packages/request-utils) provides optional utilities for managing requests and string manipulation
115+
- [@ember-data/store](../packages/store) provides core functionality around coordinating caching and reactivity
116+
- [@ember-data/tracking](../packages/tracking) enables integration with Ember's reactivity system
117+
- [@ember-data/json-api](../packages/json-api) provides a cache for data in the [{JSON:API}](https://jsonapi.org) format.
118+
- [@ember-data/debug](../packages/debug) provides (optional) debugging support for the `ember-inspector`.
119+
- [@warp-drive/build-config](../packages/build-config) provides a build plugin which ensures proper settings configuration for deprecations, optional features, development/testing support and debug logging.
120+
- [@warp-drive/core-types](../packages/core-types) provides core types and symbols used by all other packages
121+
- [@warp-drive/schema-record](../packages/schema-record) provides a flexible, schema-based approach to reactive data.
122+
- [@warp-drive/ember](../packages/ember) provides Ember specific components and utilities for reactive control-flow and declarative state management.
103123

104124
Some EmberData APIs are older than others, and these still interop via well-defined public API boundaries but are
105125
no longer the ideal approach.
106126

107-
- [@ember-data/legacy-compat](./packages/legacy-compat) provides support for older paradigms that are being phased out
108-
- [@ember-data/adapter](./packages/adapter) provides various network API integrations for APIS built over specific REST or JSON:API conventions. It integrates with the Store via `store.adapterFor`, and with the request pipeline via the `LegacyNetworkHandler` available via `@ember-data/legacy-compat` which utilizes the Minimum Adapter Interface.
109-
- [@ember-data/serializer](./packages/serializer) pairs with `@ember-data/adapter` and the `LegacyNetworkHandler` to normalize and serialize data to and from an API format into the `JSON:API` format understood by `@ember-data/json-api`.
127+
- [@ember-data/model](../packages/model) provides a class-based approach to declaring schemas for reactive data.
128+
- [@ember-data/legacy-compat](../packages/legacy-compat) provides support for the older adapter/serializer request paradigm that is being phased out
129+
- [@ember-data/adapter](../packages/adapter) provides various network API integrations for APIs built over specific REST or `{JSON:API}` conventions.
130+
- [@ember-data/serializer](../packages/serializer) provides an approach to normalizing and serializing data to and from an API format into the `{JSON:API}` format.
110131

111132
And finally:
112133

@@ -118,16 +139,44 @@ public APIs, other libraries or applications may provide their own implementatio
118139

119140
## Configuration
120141

142+
Settings configuration for deprecations, optional features, development/testing support and debug logging is done using `setConfig` in `ember-cli-build`
143+
144+
```ts
145+
'use strict';
146+
147+
const EmberApp = require('ember-cli/lib/broccoli/ember-app');
148+
149+
module.exports = async function (defaults) {
150+
const { setConfig } = await import('@warp-drive/build-config');
151+
152+
const app = new EmberApp(defaults, {});
153+
154+
setConfig(app, __dirname, {
155+
// settings here
156+
});
157+
158+
const { Webpack } = require('@embroider/webpack');
159+
return require('@embroider/compat').compatBuild(app, Webpack, {});
160+
};
161+
162+
```
163+
121164
### Deprecation Stripping
122165

123166
*Ember***Data** allows users to opt-in and remove code that exists to support deprecated behaviors.
124167

125168
If your app has resolved all deprecations present in a given version, you may specify that version as your "compatibility" version to remove the code that supported the deprecated behavior from your app.
126169

170+
You may also specify that specific deprecations are resolved. These can be used together.
171+
127172
```ts
128-
let app = new EmberApp(defaults, {
129-
emberData: {
130-
compatWith: '4.8',
173+
setConfig(app, __dirname, {
174+
// declare that all deprecations through "5.0" have been fully resolved
175+
compatWith: '5.0',
176+
177+
// mark individual deprecations as resolved by setting them to `false`
178+
deprecations: {
179+
// resolve individual deprecations here
131180
},
132181
});
133182
```
@@ -141,10 +190,8 @@ the necessary feature if your browser support or deployment environment demands
141190
activate this polyfill:
142191

143192
```ts
144-
let app = new EmberApp(defaults, {
145-
emberData: {
146-
polyfillUUID: true,
147-
},
193+
setConfig(app, __dirname, {
194+
polyfillUUID: true,
148195
});
149196
```
150197

@@ -154,10 +201,8 @@ If you do not want to ship inspector support in your production application, you
154201
that all support for it should be stripped from the build.
155202

156203
```ts
157-
let app = new EmberApp(defaults, {
158-
emberData: {
159-
includeDataAdapterInProduction: false,
160-
},
204+
setConfig(app, __dirname, {
205+
includeDataAdapterInProduction: false
161206
});
162207
```
163208

@@ -170,21 +215,21 @@ at build time. This instrumentation is always removed from production builds or
170215
that has not explicitly activated it. To activate it set the appropriate flag to `true`.
171216

172217
```ts
173-
let app = new EmberApp(defaults, {
174-
emberData: {
175-
debug: {
176-
LOG_PAYLOADS: false, // data store received to update cache with
177-
LOG_OPERATIONS: false, // updates to cache remote state
178-
LOG_MUTATIONS: false, // updates to cache local state
179-
LOG_NOTIFICATIONS: false,
180-
LOG_REQUESTS: false, // log Requests issued via the request manager
181-
LOG_REQUEST_STATUS: false,
182-
LOG_IDENTIFIERS: false,
183-
LOG_GRAPH: false, // relationship storage
184-
LOG_INSTANCE_CACHE: false, // instance creation/deletion
185-
},
218+
setConfig(app, __dirname, {
219+
includeDataAdapterInProduction: false,
220+
debug: {
221+
LOG_PAYLOADS: false, // data store received to update cache with
222+
LOG_OPERATIONS: false, // updates to cache remote state
223+
LOG_MUTATIONS: false, // updates to cache local state
224+
LOG_NOTIFICATIONS: false,
225+
LOG_REQUESTS: false, // log Requests issued via the request manager
226+
LOG_REQUEST_STATUS: false,
227+
LOG_IDENTIFIERS: false,
228+
LOG_GRAPH: false, // relationship storage
229+
LOG_INSTANCE_CACHE: false, // instance creation/deletion
186230
},
187231
});
232+
188233
```
189234

190235
### License

0 commit comments

Comments
 (0)