ruby on rails - How can an engine provide routes to the main app without using the engine's name? -


devise allows app use routes methods new_user_session_path

but if create own mountable engine authentication, have use myengine.new_user_session_path when calling in main app.

how can use routes urls devise does?

could due using normal rails engine vs mountable one?

i think there out of box way so. devise uses special stuff that. 'devise_for' method generates needed routes. path helpers routes (such 'new_user_session_path') defined in devise::controllers::urlhelpers , included actioncontroller::base.


Comments

Popular posts from this blog

css - SVG using textPath a symbol not rendering in Firefox -

Java 8 + Maven Javadoc plugin: Error fetching URL -

datatable - Matlab struct computations -