Sha256: e89521ee72f326c705e86df184e0223f85a65ad78278c44f6190777ed70a359e
Contents?: true
Size: 535 Bytes
Versions: 1
Compression:
Stored size: 535 Bytes
Contents
require "active_support/core_ext/string/access" class String remove_method :from # Returns the substring starting at a given position, spanning through # the end of the String. # # This method replaces Active Support's +String#from+. It is faster. # # @example # "abcdef".from(0) # == "abcdef" # "abcdef".from(3) # == "def" # "abcdef".from(6) # == "" # "abcdef".from(7) # == "" # # @param position [Integer] # @return [String] def from(position) self[position, self.length] end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
casual_support-3.0.2 | lib/casual_support/string/from.rb |