Sha256: d91811ec5a9988c097f2938304e59c26c67078fa3bc2c8645c05c2c9f478ec1e

Contents?: true

Size: 434 Bytes

Versions: 77

Compression:

Stored size: 434 Bytes

Contents

# frozen_string_literal: true

require "active_support/string_inquirer"
require "active_support/environment_inquirer"

class String
  # Wraps the current string in the ActiveSupport::StringInquirer class,
  # which gives you a prettier way to test for equality.
  #
  #   env = 'production'.inquiry
  #   env.production?  # => true
  #   env.development? # => false
  def inquiry
    ActiveSupport::StringInquirer.new(self)
  end
end

Version data entries

77 entries across 75 versions & 13 rubygems

Version Path
trusty-cms-7.0.9.1 vendor/bundle/ruby/3.3.0/gems/activesupport-7.0.8.7/lib/active_support/core_ext/string/inquiry.rb
minato_ruby_api_client-0.2.2 vendor/bundle/ruby/3.2.0/gems/activesupport-7.1.3.4/lib/active_support/core_ext/string/inquiry.rb
activesupport-8.0.1 lib/active_support/core_ext/string/inquiry.rb
activesupport-8.0.0.1 lib/active_support/core_ext/string/inquiry.rb
activesupport-7.2.2.1 lib/active_support/core_ext/string/inquiry.rb
activesupport-7.1.5.1 lib/active_support/core_ext/string/inquiry.rb
activesupport-7.0.8.7 lib/active_support/core_ext/string/inquiry.rb
activesupport-8.0.0 lib/active_support/core_ext/string/inquiry.rb
activesupport-7.2.2 lib/active_support/core_ext/string/inquiry.rb
activesupport-7.1.5 lib/active_support/core_ext/string/inquiry.rb
activesupport-8.0.0.rc2 lib/active_support/core_ext/string/inquiry.rb
activesupport-7.2.1.2 lib/active_support/core_ext/string/inquiry.rb
activesupport-7.1.4.2 lib/active_support/core_ext/string/inquiry.rb
activesupport-7.0.8.6 lib/active_support/core_ext/string/inquiry.rb
activesupport-8.0.0.rc1 lib/active_support/core_ext/string/inquiry.rb
activesupport-7.2.1.1 lib/active_support/core_ext/string/inquiry.rb
activesupport-7.1.4.1 lib/active_support/core_ext/string/inquiry.rb
activesupport-7.0.8.5 lib/active_support/core_ext/string/inquiry.rb
activesupport-8.0.0.beta1 lib/active_support/core_ext/string/inquiry.rb
omg-activesupport-8.0.0.alpha9 lib/active_support/core_ext/string/inquiry.rb