Function
fromIterable
(entries: Iterable<readonly [string, V]>)
Source from the content-addressed store, hash-verified
| 138 | |
| 139 | /** @internal */ |
| 140 | export const fromIterable = <V>(entries: Iterable<readonly [string, V]>) => { |
| 141 | let trie = empty<V>() |
| 142 | for (const [key, value] of entries) { |
| 143 | trie = insert(trie, key, value) |
| 144 | } |
| 145 | return trie |
| 146 | } |
| 147 | |
| 148 | /** @internal */ |
| 149 | export const make = <Entries extends Array<readonly [string, any]>>(...entries: Entries): TR.Trie< |
Tested by
no test coverage detected