Skip to content

Commit

Permalink
Improve typed schema readme (#14749)
Browse files Browse the repository at this point in the history
## Description

Add todos to typed schema readme.
  • Loading branch information
CraigMacomber authored Mar 27, 2023
1 parent cd8dc16 commit 83ad6a6
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 3 deletions.
17 changes: 17 additions & 0 deletions packages/dds/tree/src/feature-libraries/schema-aware/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
# schema-aware

Library for creating "schema aware" APIs, meaning APIs that use strong types based on schema.

TODO:

- Generate the actual APIs we need for use with Tree:
- Flexible should align with `ContextuallyTypedNodeData`
- Normalized should align with `EditableTree`. This will likely require an extra setter on editable fields and on `EditableTree` for extra fields to work around [lacking support for variant accessors for index signatures in TypeScript](https://github.com/microsoft/TypeScript/issues/43826).
- Allow use in libraries which don't have full schema information:
- Make unrestricted field types include an extra type in the union that covers the other cases generically.
- Add API for composing `TypedSchemaData`.
- Consider removing redundant information that was added to `TypedSchemaData` to make type generation work easier (or make it optional and remove the runtime copy of it).
- Support global fields.
- Support extra local fields.
- Support extra global fields (including in a way that is compatible with use in a library that does not have global schema knowledge).
- Measure compiler performance, and ensure its good enough and we have a way to track it.

This file was deleted.

0 comments on commit 83ad6a6

Please sign in to comment.