Closed SBoudrias closed 4 weeks ago
I saw later that there is backward compatibility in place: https://github.com/SBoudrias/Inquirer.js/blob/ce5d3b6ab903b43581c34f8069a6b4f108002eb1/packages/inquirer/src/ui/prompt.mts#L297-L306.
It's possible to add to backward compatibility types only: https://github.com/SBoudrias/Inquirer.js/blob/9b77c6777922cd8fd0a5c1711cf1cef19031c74b/packages/inquirer/src/types.mts#L50-L57
Of course if the string support is added to choices, the backward compatibility can be dropped.
Ohh I forgot about that. I'll still bring it over to @inquirer/*
since it makes migration easier.
Ref #1527
Inquirer v9 & prior allowed choices to be array of strings. Given how widespread that pattern is, we should maintain this backward compatibility. It'll also simplify the work of folks migrating from
inquirer
to@inquirer/prompts
with less code change.TODO