Skip to content

Commit 470dabc

Browse files
authored
convert transient component/entities to ephemeral to avoid confusion with transient operations (#89)
* convert transient component/entities to ephemeral to avoid confusion with transient operations * Add ephemeral flag to TransactionResult and unify ephemeral resources - Add `ephemeral: boolean` to TransactionResult, true when all changed entities have negative IDs (ephemeral entities) - Refactor Entity into namespace folder with Entity.isEphemeral utility - Resources with schema.ephemeral now create ephemeral entities (negative IDs) instead of only resetting values on deserialize - Update coalesceTransactions, observed database, and storage persistence to propagate and respect the ephemeral flag - Skip ephemeral-only transactions in createStoragePersistenceService - Add comprehensive tests for ephemeral flag across entity operations, resource mutations, mixed changes, and transaction coalescing Made-with: Cursor * bumped
1 parent f6357e0 commit 470dabc

54 files changed

Lines changed: 442 additions & 154 deletions

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "data-monorepo",
3-
"version": "0.9.45",
3+
"version": "0.9.47",
44
"private": true,
55
"scripts": {
66
"build": "pnpm -r run build",

packages/data-lit-tictactoe/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "data-lit-tictactoe",
3-
"version": "0.9.45",
3+
"version": "0.9.47",
44
"description": "Tic-Tac-Toe sample - Lit web components with @adobe/data-lit and AgenticService",
55
"type": "module",
66
"private": true,

packages/data-lit-todo/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "data-lit-todo",
3-
"version": "0.9.43",
3+
"version": "0.9.45",
44
"description": "Todo sample app demonstrating @adobe/data with Lit",
55
"type": "module",
66
"private": true,

packages/data-lit/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@adobe/data-lit",
3-
"version": "0.9.45",
3+
"version": "0.9.47",
44
"description": "Adobe data Lit bindings - hooks, elements, decorators",
55
"type": "module",
66
"private": false,

packages/data-react-hello/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "data-react-hello",
3-
"version": "0.9.45",
3+
"version": "0.9.47",
44
"description": "Hello World sample - click counter using @adobe/data-react",
55
"type": "module",
66
"private": true,

packages/data-react-pixie/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "data-react-pixie",
3-
"version": "0.9.45",
3+
"version": "0.9.47",
44
"description": "PixiJS React sample - ECS sprites (bunny, fox) with @adobe/data-react",
55
"type": "module",
66
"private": true,

packages/data-react/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@adobe/data-react",
3-
"version": "0.9.45",
3+
"version": "0.9.47",
44
"description": "Adobe data React bindings — hooks and context for ECS database",
55
"type": "module",
66
"private": false,

packages/data/AGENTS.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,7 @@ Source lives under `src/` with one main `index.ts` per area; built output is in
7272
|----------|---------|
7373
| `extends` | Base plugin to extend (single parent only) |
7474
| `services` | `(db) => ServiceInstance` — singleton service factories; extended plugin services initialize first |
75-
| `components` | Schema object for ECS component data. Use `transient: true` for non-persistable values (DOM refs, HTML elements). |
75+
| `components` | Schema object for ECS component data. Use `ephemeral: true` for non-persistable values (DOM refs, HTML elements). |
7676
| `resources` | `{ default: value as Type }` — global state. Use `as Type` for compile-time type; use `null as unknown as Type` for resources initialized later in a system. |
7777
| `archetypes` | `['comp1', 'comp2']` — standard ECS archetypes for querying and inserting related components |
7878
| `computed` | `(db) => Observe<T>` — factory returning observable; receives full db |

packages/data/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@adobe/data",
3-
"version": "0.9.45",
3+
"version": "0.9.47",
44
"description": "Adobe data oriented programming library",
55
"type": "module",
66
"sideEffects": false,

packages/data/src/ecs/archetype/archetype.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
// © 2026 Adobe. MIT License. See /LICENSE for details.
22
import { RequiredComponents } from "../required-components.js";
3-
import { Entity } from "../entity.js";
3+
import { Entity } from "../entity/entity.js";
44
import { Table, ReadonlyTable } from "../../table/index.js";
55
import { Assert } from "../../types/assert.js";
66
import { Equal } from "../../types/equal.js";

0 commit comments

Comments
 (0)