Class: Modular::ComponentGenerator
- Inherits:
-
Rails::Generators::NamedBase
- Object
- Rails::Generators::NamedBase
- Modular::ComponentGenerator
- Defined in:
- lib/modular/generators/component/component_generator.rb
Instance Method Summary collapse
Instance Method Details
#generate_controller ⇒ Object
9 10 11 |
# File 'lib/modular/generators/component/component_generator.rb', line 9 def generate_controller template "template.erb", "app/views/components/#{filename}.html.erb" end |
#generate_template ⇒ Object
5 6 7 |
# File 'lib/modular/generators/component/component_generator.rb', line 5 def generate_template template "component.rb.erb", "app/components/#{filename}.rb" end |