You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Some functionality I could not find in the library, but would help adaptation IMO.
fork.path - I am currently prepending the prefixes of forks, in order to get full paths in the end. Maybe this could be done during load by the library and provide it as a string or Uint8Array on Fork
findAllValueForks - For a given node, collect all value Forks, so user space code does not have to recursively walk through the forks and filter them.
addFork and removePath - could accept string | Uint8Array instead of Uint8Array only, so the user space code does not need to apply new TextEncoder().encode(path) for all the calls. Similarly, reference could accept string too, assumed to be a hex representation of 32 or 64 bytes data.
The text was updated successfully, but these errors were encountered:
fork.path - I am currently prepending the prefixes of forks, in order to get full paths in the end. Maybe this could be done during load by the library and provide it as a string or Uint8Array on Fork
I would rather create a separate utility function or abstraction for this feature, but surely I wouldn't put any additional property to the mantaray fork or node which is related to the trie structure. I'm saying this because many cases you want to move fork/node to one place to another and you shouldn't maintain/update these additional meta-properties during these kind of processes.
findAllValueForks - For a given node, collect all value Forks, so user space code does not have to recursively walk through the forks and filter them.
good idea : )
addFork and removePath - could accept string | Uint8Array instead of Uint8Array only, so the user space code does not need to apply new TextEncoder().encode(path) for all the calls. Similarly, reference could accept string too, assumed to be a hex representation of 32 or 64 bytes data.
I think this convenient feature is justified to be added and with it little bit diverge from the reference implementation's interface.
Some functionality I could not find in the library, but would help adaptation IMO.
fork.path
- I am currently prepending the prefixes of forks, in order to get full paths in the end. Maybe this could be done duringload
by the library and provide it as astring
orUint8Array
onFork
findAllValueForks
- For a given node, collect all valueForks
, so user space code does not have to recursively walk through the forks and filter them.addFork
andremovePath
- could acceptstring | Uint8Array
instead ofUint8Array
only, so the user space code does not need to applynew TextEncoder().encode(path)
for all the calls. Similarly,reference
could acceptstring
too, assumed to be a hex representation of 32 or 64 bytes data.The text was updated successfully, but these errors were encountered: