Skip to content

Commit

Permalink
Don't error if turbo-rails is required on an unsupported Rails version
Browse files Browse the repository at this point in the history
  • Loading branch information
boardfish committed Aug 2, 2024
1 parent e18bcf5 commit 5938273
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 0 deletions.
5 changes: 5 additions & 0 deletions Gemfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -308,6 +308,10 @@ GEM
thor (1.3.1)
tilt (2.4.0)
timeout (0.4.1)
turbo-rails (1.5.0)
actionpack (>= 6.0.0)
activejob (>= 6.0.0)
railties (>= 6.0.0)
tzinfo (2.0.6)
concurrent-ruby (~> 1.0)
unicode-display_width (2.5.0)
Expand Down Expand Up @@ -355,6 +359,7 @@ DEPENDENCIES
slim (~> 5.1)
sprockets-rails (~> 3.4.2)
standard (~> 1)
turbo-rails (~> 1)
view_component!
warning
yard (~> 0.9.34)
Expand Down
5 changes: 5 additions & 0 deletions test/sandbox/config/application.rb
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,11 @@
require "action_mailer/railtie"
require "action_view/railtie"
require "sprockets/railtie"
begin
require "turbo-rails"
rescue LoadError
raise if Rails::VERSION::MAJOR >= 6
end

# Track when different Rails frameworks get loaded.
# Ideally, none of them should be loaded until after initialization is complete.
Expand Down

0 comments on commit 5938273

Please sign in to comment.