Skip to content

Conversation

@brabeji
Copy link

@brabeji brabeji commented Sep 1, 2024

I spent some time on this, so I'm sharing it as a short draft. LMK if this is the right direction for the API.

json-joy is impressive stuff, thank you @streamich

}

export type JsonNodeView<N> = N extends JsonNode<infer V> ? V : {[K in keyof N]: JsonNodeView<N[K]>};
export type JsonNodeView<N> = N extends ExtNode<any, infer V>
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not sure if the first branch is necessary

@brabeji brabeji force-pushed the dynamic-ext-view-types branch from 8ae7ac0 to e6015e2 Compare September 1, 2024 21:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

1 participant