Mount Applications Mount Hanami and Rack applications in Hanami projects
Mount Applications
If we want to mount an application, we should use mount within the Hanami environment configuration file.
The global configuration file is located at config/environment.rb.
Place mount within the Hanami.configure block.
# config/environment.rb
Hanami.configure do
mount Web::Application, at: "/"
mount OtherApplication.new, at: "/other"
mount SinatraApp.new, at: "/sinatra"
# ...
endAll the HTTP requests starting with /sinatra will be routed to SinatraApp.
Learn more at Routing overview guide.
Twitter Facebook