Sha256: c64c762c57885c5f240e17a398d47ebe21e521d7bd08940dbae2ea7ef9ba1e07

Contents?: true

Size: 367 Bytes

Versions: 2

Compression:

Stored size: 367 Bytes

Contents

class String
  # The following is overkill right now, as the only necessarily insignificant characters are whitespace.
  #def significant; chars.select(&:significant?).join; end
  #def significant; gsub(/\s+/, ''); end # whoa that does not have the effect i want it to have.
  def significant
    strip
  end

  def strictly_significant
    gsub(/\s+/, '')
  end
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
significance-0.2.1 lib/significance/core_ext/string.rb
significance-0.2.0 lib/significance/core_ext/string.rb