Sha256: 41096005db912d6a65299578b1b15d7db6387d7b1e90abf9e317d27d01300812
Contents?: true
Size: 680 Bytes
Versions: 24
Compression:
Stored size: 680 Bytes
Contents
# frozen_string_literal: true # :markup: markdown require "active_support/core_ext/module/introspection" module AbstractController module Railties module RoutesHelpers def self.with(routes, include_path_helpers = true) Module.new do define_method(:inherited) do |klass| super(klass) if namespace = klass.module_parents.detect { |m| m.respond_to?(:railtie_routes_url_helpers) } klass.include(namespace.railtie_routes_url_helpers(include_path_helpers)) else klass.include(routes.url_helpers(include_path_helpers)) end end end end end end end
Version data entries
24 entries across 24 versions & 2 rubygems