Xema.Format.host-question-mark
You're seeing just the function
host-question-mark
, go back to Xema.Format module for more information.
Specs
Checks if the string
is a valid host representation.
This function returns true
if the value is a valid IPv4 address, IPv6
address, or a valid hostname, false
otherwise.
Examples
iex> import Xema.Format
iex>
iex> host?("127.0.0.1")
true
iex> host?("localhost")
true
iex> host?("elixirforum.com")
true
iex> host?("go go go")
false