(
env: Record<string, string | undefined>,
options?: { readonly preserveEmptyStrings?: boolean | undefined }
)
| 880 | * @since 4.0.0 |
| 881 | */ |
| 882 | export function fromEnvRecord( |
| 883 | env: Record<string, string | undefined>, |
| 884 | options?: { readonly preserveEmptyStrings?: boolean | undefined } |
| 885 | ): ConfigProvider { |
| 886 | const preserveEmptyStrings = options?.preserveEmptyStrings === true |
| 887 | const trie = buildEnvTrie(env) |
| 888 | return make((path) => Effect.succeed(nodeAtEnv(trie, env, path, preserveEmptyStrings))) |
| 889 | } |
| 890 | |
| 891 | /** |
| 892 | * Creates a `ConfigProvider` backed by environment variables. |
no test coverage detected