Class: Suspenders::ViewsGenerator
Instance Method Summary
collapse
default_source_root, inherited
#bundle_command
Methods included from Actions
#action_mailer_asset_host, #action_mailer_host, #configure_environment, #expand_json, #gem, #replace_in_file
Instance Method Details
#create_application_layout ⇒ Object
19
20
21
22
23
|
# File 'lib/suspenders/generators/views_generator.rb', line 19
def create_application_layout
template "suspenders_layout.html.erb.erb",
"app/views/layouts/application.html.erb",
force: true
end
|
#create_partials_directory ⇒ Object
5
6
7
|
# File 'lib/suspenders/generators/views_generator.rb', line 5
def create_partials_directory
empty_directory "app/views/application"
end
|
#create_shared_css_overrides ⇒ Object
14
15
16
17
|
# File 'lib/suspenders/generators/views_generator.rb', line 14
def create_shared_css_overrides
copy_file "_css_overrides.html.erb",
"app/views/application/_css_overrides.html.erb"
end
|
#create_shared_flashes ⇒ Object
9
10
11
12
|
# File 'lib/suspenders/generators/views_generator.rb', line 9
def create_shared_flashes
copy_file "_flashes.html.erb", "app/views/application/_flashes.html.erb"
copy_file "flashes_helper.rb", "app/helpers/flashes_helper.rb"
end
|