class ViewComponent::Compiler
def templates
Experimental RBS support (using type sampling data from the type_fusion
project).
def templates: () -> Array[Hash, path, String, variant, NilClass, handler, String]
This signature was generated using 14 samples from 2 applications.
def templates @templates ||= begin extensions = ActionView::Template.template_handler_extensions component_class.sidecar_files(extensions).each_with_object([]) do |path, memo| pieces = File.basename(path).split(".") memo << { path: path, variant: pieces[1..-2].join(".").split("+").second&.to_sym, handler: pieces.last } end end end