Class: InertiaRails::InstallGenerator

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

Constant Summary collapse

FRONT_END_INSTALLERS =
[
  'react',
  'vue',
  'svelte',
]

Instance Method Summary collapse

Instance Method Details

#installObject



12
13
14
15
16
17
18
19
20
# File 'lib/generators/inertia_rails/install_generator.rb', line 12

def install
  exit! unless installable?

  install_base!

  send "install_#{options[:front_end]}!"

  say "You're all set! Run rails s and checkout localhost:3000/inertia-example", :green
end