v4 schemas #22
GreenArrow18
started this conversation in
General
Replies: 3 comments 8 replies
|
I created new repository with new user here https://github.com/PackBytes/pack selectOne is the old schema = selectOne({ field1: bool, field2: bool })
const { encode, decode } = PackBytes(schema)
data = { field1: true }
encode(data) |
0 replies
|
This new repository appears to be missing now. Can this be merged to main, if there were changes? Thanks! |
4 replies
|
Hello again. In the old version, the following schema was possible: This saves significant space, since the strings are known already. What's the equivalent in the new repo? Above still works, but it looks like it doesn't auto-map to integers anymore? |
4 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
What is the equivalent of schemas in v4? Is it union? Or select? What's the difference?
Also, there used to be:
encode(schema_name, data)
How to do this in v4 now?
Thanks.
All reactions