class ActionView::DependencyTracker
Experimental RBS support (using type sampling data from the type_fusion
project).
# sig/action_view/dependency_tracker.rbs class ActionView::DependencyTracker def self.register_tracker: (Symbol extension, Class tracker) -> Class end
:nodoc:
def self.find_dependencies(name, template, view_paths = nil)
def self.find_dependencies(name, template, view_paths = nil) tracker = @trackers[template.handler] return [] unless tracker tracker.call(name, template, view_paths) end
def self.register_tracker(extension, tracker)
Experimental RBS support (using type sampling data from the type_fusion
project).
def self.register_tracker: (Symbol extension, Class tracker) -> Class
This signature was generated using 5 samples from 1 application.
def self.register_tracker(extension, tracker) handler = Template.handler_for_extension(extension) if tracker.respond_to?(:supports_view_paths?) @trackers[handler] = tracker else @trackers[handler] = lambda { |name, template, _| tracker.call(name, template) } end end
def self.remove_tracker(handler)
def self.remove_tracker(handler) @trackers.delete(handler) end