debian-mirror-gitlab/config/initializers/hamlit.rb

19 lines
388 B
Ruby
Raw Normal View History

2016-08-24 12:49:21 +05:30
module Hamlit
class TemplateHandler
def call(template)
Engine.new(
generator: Temple::Generators::RailsOutputBuffer,
attr_quote: '"',
).call(template.source)
end
end
end
ActionView::Template.register_template_handler(
:haml,
Hamlit::TemplateHandler.new,
)
Hamlit::Filters.remove_filter('coffee')
Hamlit::Filters.remove_filter('coffeescript')