Sha256: 35128af46bb84a8068a6b8210a845908186e7c3b92d1c168d688bf23a379baab

Contents?: true

Size: 380 Bytes

Versions: 132

Compression:

Stored size: 380 Bytes

Contents

module CmAdmin
  class VersionManager
    class << self
      def rails6?
        Rails::VERSION::MAJOR == 6
      end

      def rails7?
        Rails::VERSION::MAJOR == 7
      end

      def use_importmap?
        rails7? && File.exist?('config/importmap.rb')
      end

      def use_webpacker?
        rails6? && defined?(Webpacker) == 'constant'
      end
    end
  end
end

Version data entries

132 entries across 132 versions & 1 rubygems

Version Path
cm-admin-3.0.16 lib/cm_admin/version_manager.rb
cm-admin-3.0.15 lib/cm_admin/version_manager.rb
cm-admin-3.0.14 lib/cm_admin/version_manager.rb
cm-admin-3.0.13 lib/cm_admin/version_manager.rb
cm-admin-3.0.12 lib/cm_admin/version_manager.rb
cm-admin-3.0.11 lib/cm_admin/version_manager.rb
cm-admin-3.0.10 lib/cm_admin/version_manager.rb
cm-admin-3.0.9 lib/cm_admin/version_manager.rb
cm-admin-3.0.8 lib/cm_admin/version_manager.rb
cm-admin-3.0.7 lib/cm_admin/version_manager.rb
cm-admin-3.0.6 lib/cm_admin/version_manager.rb
cm-admin-3.0.5 lib/cm_admin/version_manager.rb
cm-admin-3.0.4 lib/cm_admin/version_manager.rb
cm-admin-3.0.3 lib/cm_admin/version_manager.rb
cm-admin-3.0.2 lib/cm_admin/version_manager.rb
cm-admin-3.0.1 lib/cm_admin/version_manager.rb
cm-admin-3.0.0 lib/cm_admin/version_manager.rb
cm-admin-2.4.6 lib/cm_admin/version_manager.rb
cm-admin-2.4.5 lib/cm_admin/version_manager.rb
cm-admin-2.4.4 lib/cm_admin/version_manager.rb