Module: BackboneHandlebars::Generators::Helpers
- Included in:
- InstallGenerator
- Defined in:
- lib/generators/backbone_handlebars/helpers.rb
Instance Method Summary collapse
- #app_name ⇒ Object
- #assets_path ⇒ Object
- #collections_path ⇒ Object
- #helpers_path ⇒ Object
- #javascripts_path ⇒ Object
- #models_path ⇒ Object
- #production_config_path ⇒ Object
- #routers_path ⇒ Object
- #templates_path ⇒ Object
- #views_path ⇒ Object
Instance Method Details
#app_name ⇒ Object
41 42 43 |
# File 'lib/generators/backbone_handlebars/helpers.rb', line 41 def app_name Rails.application.class.name.split('::').first.camelize end |
#assets_path ⇒ Object
5 6 7 |
# File 'lib/generators/backbone_handlebars/helpers.rb', line 5 def assets_path File.join('app', 'assets') end |
#collections_path ⇒ Object
17 18 19 |
# File 'lib/generators/backbone_handlebars/helpers.rb', line 17 def collections_path File.join(javascripts_path, 'collections') end |
#helpers_path ⇒ Object
21 22 23 |
# File 'lib/generators/backbone_handlebars/helpers.rb', line 21 def helpers_path File.join(javascripts_path, 'helpers') end |
#javascripts_path ⇒ Object
9 10 11 |
# File 'lib/generators/backbone_handlebars/helpers.rb', line 9 def javascripts_path File.join(assets_path, 'javascripts') end |
#models_path ⇒ Object
13 14 15 |
# File 'lib/generators/backbone_handlebars/helpers.rb', line 13 def models_path File.join(javascripts_path, 'models') end |
#production_config_path ⇒ Object
37 38 39 |
# File 'lib/generators/backbone_handlebars/helpers.rb', line 37 def production_config_path File.join('config', 'environments', 'production.rb') end |
#routers_path ⇒ Object
25 26 27 |
# File 'lib/generators/backbone_handlebars/helpers.rb', line 25 def routers_path File.join(javascripts_path, 'routers') end |
#templates_path ⇒ Object
33 34 35 |
# File 'lib/generators/backbone_handlebars/helpers.rb', line 33 def templates_path File.join(javascripts_path, 'templates') end |
#views_path ⇒ Object
29 30 31 |
# File 'lib/generators/backbone_handlebars/helpers.rb', line 29 def views_path File.join(javascripts_path, 'views') end |