Method: String#nothing?

Defined in:
lib/extra/string.rb

#nothing?Boolean

Checks if a string is nothing but whitespace or is empty.

Example: " ".nothing? #=> true

Returns: True or false

Returns:



224
225
226
# File 'lib/extra/string.rb', line 224

def nothing?
  strip.empty?
end