Module: Primer::Forms::ActsAsComponent
- Included in:
 - Base, BaseComponent, FormList
 
- Defined in:
 - lib/primer/forms/acts_as_component.rb
 
Overview
:nodoc:
Defined Under Namespace
Modules: InstanceMethods Classes: TemplateGlob, TemplateParams
Instance Attribute Summary collapse
- 
  
    
      #template_root_path  ⇒ Object 
    
    
  
  
  
  
    
    
  
  
  
  
  
  
    
Returns the value of attribute template_root_path.
 
Class Method Summary collapse
Instance Method Summary collapse
- #compile! ⇒ Object
 - #renders_templates(glob_pattern, method_name = nil, &block) ⇒ Object (also: #renders_template)
 
Instance Attribute Details
#template_root_path ⇒ Object
Returns the value of attribute template_root_path.
      53 54 55  | 
    
      # File 'lib/primer/forms/acts_as_component.rb', line 53 def template_root_path @template_root_path end  | 
  
Class Method Details
.extended(base) ⇒ Object
      46 47 48  | 
    
      # File 'lib/primer/forms/acts_as_component.rb', line 46 def self.extended(base) base.include(InstanceMethods) end  | 
  
Instance Method Details
#compile! ⇒ Object
      60 61 62 63 64 65 66 67 68 69  | 
    
      # File 'lib/primer/forms/acts_as_component.rb', line 60 def compile! # always recompile in dev return if defined?(@compiled) && @compiled && !Rails.env.development? template_globs.each do |template_glob| compile_templates_in(template_glob) end @compiled = true end  | 
  
#renders_templates(glob_pattern, method_name = nil, &block) ⇒ Object Also known as: renders_template
      55 56 57  | 
    
      # File 'lib/primer/forms/acts_as_component.rb', line 55 def renders_templates(glob_pattern, method_name = nil, &block) template_globs << TemplateGlob.new(glob_pattern, method_name, block) end  |