Select the mode at the very beginning
Closed this issue · 2 comments
ArturGudiev commented
Just a question.
Is it possible to select the mode when you call node-fzf. I mean, I would like to have a normal mode (not fuzzy) at the very beginning. Or the only option to switch the mode is to press the hotkey Cntrl+S
?
talmobi commented
Yes just use an options object with mode: 'normal'
e.g.
const normalMode = true
const opts = {
mode: normalMode ? 'normal' : 'fuzzy',
list: ['one, 'two', 'three']
}
const api = nfzf( opts, function ( result ) {
...snip...
ArturGudiev commented
Thanks!