Closed AlfredBrandon closed 3 months ago
`# frozen_string_literal: true
module Ditty class AutomatedActions class << self
begin def routes controllers = File.expand_path('../../automatedactions/controllers', __dir__) Dir.glob("#{controllers}/*.rb").sort.each { |f| require f } { '/rules' => ::AutomatedActions::RuleController, '/domains' => ::AutomatedActions::DomainController, '/conditions' => ::AutomatedActions::ConditionController, } end end end
end end
Ditty::Components.register_component(:automatedactions, Ditty::AutomatedActions)`
I have added a new component and read the documentation on how to add a new component . When I added the above component it doesn't want to register on Ditty.
Found the issue thanks as part of the application.rb you also need to register the new component.
`# frozen_string_literal: true
module Ditty class AutomatedActions class << self
end end
Ditty::Components.register_component(:automatedactions, Ditty::AutomatedActions)`
I have added a new component and read the documentation on how to add a new component . When I added the above component it doesn't want to register on Ditty.