(
initialState: State | Effect.Effect<State, never, Environment>,
...args:
| [handlers: Handlers<State, Output, Terminal.UserInput>]
| [events: Queue.Dequeue<A, never>, handlers: Handlers<State, Output, ProcessInput<A>>]
)
| 946 | handlers: Handlers<State, Output, ProcessInput<A>> |
| 947 | ): Prompt<Output> |
| 948 | } = <State, Output, A>( |
| 949 | initialState: State | Effect.Effect<State, never, Environment>, |
| 950 | ...args: |
| 951 | | [handlers: Handlers<State, Output, Terminal.UserInput>] |
| 952 | | [events: Queue.Dequeue<A, never>, handlers: Handlers<State, Output, ProcessInput<A>>] |
| 953 | ): Prompt<Output> => { |
| 954 | const [events, handlers] = args.length === 1 |
| 955 | ? [undefined, args[0]] as const |
| 956 | : [args[0], args[1]] as const |
| 957 | const op = Object.create(proto) |
| 958 | op._tag = "Loop" |
| 959 | op.initialState = initialState |
| 960 | op.render = handlers.render |
| 961 | op.process = handlers.process |
| 962 | op.clear = handlers.clear |
| 963 | op.events = events |
| 964 | return op |
| 965 | } |
| 966 | |
| 967 | /** |
| 968 | * Creates a date prompt that lets the user edit a formatted date value and |
no outgoing calls
no test coverage detected