ExPrompt.string

You're seeing just the function string, go back to ExPrompt module for more information.
Link to this function

string(prompt, default \\ "")

View Source

Specs

string(prompt(), String.t()) :: String.t()

Reads a line from :stdio displaying the prompt that is passed in.

In case of any errors or :eof this function will return the default value if present, or an empty string otherwise.

Examples

To ask a user for their name and await for the input:

ExPrompt.string("What is your name? ")

To ask for a hostname defaulting to localhost:

ExPrompt.string("What is the hostname? ", "localhost")