Sha256: 7ef31301ba34ebef2a44b526caa8369dbaed0243c7e95e2585fce605c55dca13

Contents?: true

Size: 245 Bytes

Versions: 70

Compression:

Stored size: 245 Bytes

Contents

class String
  def demodulize
    if i = self.rindex("::")
      self[(i + 2)..-1]
    else
      self
    end
  end

  def deconstantize
    self[0, self.rindex("::") || 0] # implementation based on the one in facets' Module#spacename
  end
end

Version data entries

70 entries across 70 versions & 1 rubygems

Version Path
isomorfeus-react-16.8.0 lib/react/active_support_support.rb
isomorfeus-react-16.6.8 lib/react/active_support_support.rb
isomorfeus-react-16.6.7 lib/react/active_support_support.rb
isomorfeus-react-16.6.6 lib/react/active_support_support.rb
isomorfeus-react-16.6.5 lib/react/active_support_support.rb
isomorfeus-react-16.6.4 lib/react/active_support_support.rb
isomorfeus-react-16.6.3 lib/react/active_support_support.rb
isomorfeus-react-16.6.2 lib/react/active_support_support.rb
isomorfeus-react-16.6.1 lib/react/active_support_support.rb
isomorfeus-react-16.5.1 lib/react/active_support_support.rb