method

blank?

v4.0.2 - Show latest stable - Class: String
blank?()
public

A string is blank if it’s empty or contains whitespaces only:

''.blank?                 # => true
'   '.blank?              # => true
' '.blank?               # => true
' something here '.blank? # => false