(json: unknown)
| 717 | |
| 718 | /** @internal */ |
| 719 | export const fromJson = (json: unknown): ConfigProvider.ConfigProvider => { |
| 720 | const hiddenDelimiter = "\ufeff" |
| 721 | const indexedEntries = Arr.map( |
| 722 | getIndexedEntries(json as JsonMap), |
| 723 | ([key, value]): [string, string] => [configPathToString(key).join(hiddenDelimiter), value] |
| 724 | ) |
| 725 | return fromMap(new Map(indexedEntries), { |
| 726 | pathDelim: hiddenDelimiter, |
| 727 | seqDelim: hiddenDelimiter |
| 728 | }) |
| 729 | } |
| 730 | |
| 731 | const configPathToString = (path: ReadonlyArray<KeyComponent>): ReadonlyArray<string> => { |
| 732 | const output: Array<string> = [] |
nothing calls this directly
no test coverage detected