(Multi)Select behaves as input in the Deno
vikiival opened this issue · 1 comments
vikiival commented
Environment
deno 1.37.2 (release, aarch64-apple-darwin)
v8 11.8.172.13
typescript 5.2.2
import { consola } from 'https://esm.sh/consola@3.2.3'
Reproduction
https://replit.com/@vikiival/consola-promt
MVP:
import { consola } from 'https://esm.sh/consola@3.2.3'
const projectType = await consola.prompt("Pick a project type.", {
type: "select",
options: [
"TypeScript",
"TypeScript",
{ label: "CoffeeScript", value: "CoffeeScript", hint: "oh no" },
],
});
consola.info("You picked", projectType);
deno run -A main.ts
Describe the bug
I was trying to run a simple example of consola.prompt
in Deno with the option of select
and it returns the default prompt type.
Additional context
No response
Logs
Pick a project type. dasda
info You picked dasda
peterroe commented
It seem: consola.prompt
is not fully compatible with deno
. Because prompt
is used net.Socket.prototype.constructor
internally, And deno
hasn't achieve it.