class Tapioca::Dsl::Compilers::UrlHelpers
def generate_module_for(root, constant)
def generate_module_for(root, constant) root.create_module(T.must(constant.name)) do |mod| mod.create_include("::ActionDispatch::Routing::UrlFor") mod.create_include("::ActionDispatch::Routing::PolymorphicRoutes") constant.instance_methods(false).each do |method| mod.create_method( method.to_s, parameters: [create_rest_param("args", type: "T.untyped")], return_type: "String", ) end end end