Class: Bs5ExpandableListGroup::InstallGenerator

Inherits:
Rails::Generators::Base
  • Object
show all
Defined in:
lib/generators/bs5_expandable_list_group/install/install_generator.rb

Instance Method Summary collapse

Instance Method Details

#copy_cssObject



14
15
16
# File 'lib/generators/bs5_expandable_list_group/install/install_generator.rb', line 14

def copy_css
  directory 'stylesheets', 'app/javascript/stylesheets'
end

#copy_jsObject



10
11
12
# File 'lib/generators/bs5_expandable_list_group/install/install_generator.rb', line 10

def copy_js
  directory 'controllers', 'app/javascript/controllers'
end

#list_prerequisitesObject



4
5
6
7
8
# File 'lib/generators/bs5_expandable_list_group/install/install_generator.rb', line 4

def list_prerequisites
  # We can add functionality to install hotwire automatically.
  exit if no?('Do you have Stimulus or Hotwire installed? [Y/n]')
  exit if no?('Do you have Bootstrap 5 installed and configured properly? [Y/n]')
end