Closed rcjiang closed 2 years ago
@rcjiang What do you mean, I just can't get, can you describe more info about this
@anc95
My options:
{
name: 'folder',
type: 'inquirer-file-tree-selection',
message: 'Select a folder:',
onlyShowDir: true,
default: './src'
}
The default
option was added and configured as './src', I expect the next step it should be selected by default(show highlighted):
The actual result is:the default seleted is the first folder not "./src"
Essentially, this issue is the same as:#25
@rcjiang I totally understood what do you mean, I will work this today and implement default
the same behavior as inquirejs's internal prompt. Give me some time, I will notify you here when new version is released. Thx for your feedback.
@rcjiang Good news, I just release 1.0.15 to support this feature, readme updated for usage of default
, and I added a demo https://github.com/anc95/inquirer-file-tree-selection/blob/main/example/default.js, you can go to see how to use.