Skip to content

Instantly share code, notes, and snippets.

@luizbranco luizbranco/main.go
Last active Nov 23, 2017

Embed
What would you like to do?
promptui demo step 2
prompt := promptui.Prompt{
Label: "Search",
Validate: func(input string) error {
if len(input) < 3 {
return errors.New("Search term must have at least 3 characters")
}
return nil
},
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.