Skip to content
This repository has been archived by the owner on Jan 13, 2025. It is now read-only.

Enhanece and test Typescript types #8

Open
wants to merge 7 commits into
base: master
Choose a base branch
from

Conversation

devnev
Copy link

@devnev devnev commented Dec 31, 2024

This is building on top of #6 by @vekexasia

Most notaby, this encodes undefined property names in the P type, which is used in Structure to omit fields without a property name.

A note on the approach, the class constructors are more loosely typed, while the constructor functions have overloads with stricter types.

This PR includes a typed examples test file to give an idea that it works, but the tests are pretty minimal and there's no negative tests (i.e. tests that compilation fails) despite that kinda being the goal of the type enhancements.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants