Sha256: 9a6ed7b2d5f23801338b59a75ec49021c5d96262af68e9098dc6b6030d0349d3

Contents?: true

Size: 576 Bytes

Versions: 15

Compression:

Stored size: 576 Bytes

Contents

# This file is here to integrate with Rails 3,
# since there's no better way to do so as of 14 March 2010.
# Yehuda promises there will be soon,
# and once there is we should switch to that.

if defined?(ActiveSupport) && Haml::Util.has?(:public_method, ActiveSupport, :on_load)
  # Rails 3.0.0.beta.2+
  ActiveSupport.on_load(:action_view) {Haml.init_rails(binding)}
elsif defined?(Rails::Railtie)
  # Rails 3.0.0.beta1
  module Haml
    class Railtie < Rails::Railtie
      ActiveSupport.on_load(:action_view) do
        Haml.init_rails(binding)
      end
    end
  end
end

Version data entries

15 entries across 15 versions & 2 rubygems

Version Path
haml-edge-2.3.222 lib/haml/railtie.rb
haml-3.0.0.rc.2 lib/haml/railtie.rb
haml-edge-2.3.221 lib/haml/railtie.rb
haml-edge-2.3.220 lib/haml/railtie.rb
haml-edge-2.3.219 lib/haml/railtie.rb
haml-edge-2.3.218 lib/haml/railtie.rb
haml-edge-2.3.217 lib/haml/railtie.rb
haml-edge-2.3.216 lib/haml/railtie.rb
haml-edge-2.3.215 lib/haml/railtie.rb
haml-edge-2.3.214 lib/haml/railtie.rb
haml-edge-2.3.213 lib/haml/railtie.rb
haml-edge-2.3.212 lib/haml/railtie.rb
haml-edge-2.3.211 lib/haml/railtie.rb
haml-edge-2.3.210 lib/haml/railtie.rb
haml-3.0.0.rc.1 lib/haml/railtie.rb