(name?: string)
| 192 | |
| 193 | /** @internal */ |
| 194 | export const url = (name?: string): Config.Config<URL> => { |
| 195 | const config = primitive( |
| 196 | "an URL property", |
| 197 | (text) => |
| 198 | Either.try({ |
| 199 | try: () => new URL(text), |
| 200 | catch: (_) => configError.InvalidData([], `Expected an URL value but received ${formatUnknown(text)}`) |
| 201 | }) |
| 202 | ) |
| 203 | return name === undefined ? config : nested(config, name) |
| 204 | } |
| 205 | |
| 206 | /** @internal */ |
| 207 | export const port = (name?: string): Config.Config<number> => { |
nothing calls this directly
no test coverage detected