blob: 5b16acab0488e2e81fdc28091ae7e9bf2704e38b (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
|
require "rails/engine"
module ActiveText
class Engine < Rails::Engine
isolate_namespace ActiveText
config.eager_load_namespaces << ActiveText
initializer "active_text.attribute" do
ActiveSupport.on_load(:active_record) do
include ActiveText::Attribute
end
end
# FIXME: Aren't helpers supposed to load automatically?
# https://github.com/rails/rails/issues/26627 ?
initializer "active_text.helper" do
ActiveSupport.on_load(:action_controller_base) do
helper ActiveText::TagHelper
end
end
end
end
|