Sha256: 33654a5ba93d84a3233e121ccaae4aaea8a805d8b0abcde2420a77c6217af59f
Contents?: true
Size: 497 Bytes
Versions: 11
Compression:
Stored size: 497 Bytes
Contents
module NavigationHelpers def path_to(page_name) case page_name when /the homepage/i root_path when /the sign up page/i new_user_path when /the sign in page/i new_session_path when /the password reset request page/i new_password_path # Add more page name => path mappings here else raise "Can't find mapping from \"#{page_name}\" to a path." end end end World do |world| world.extend NavigationHelpers world end
Version data entries
11 entries across 11 versions & 3 rubygems