Get Started
Install and configure TurboBoost Streams in your Rails/Hotwire app
-
First, add the GEM to your
Gemfile
.bundle add turbo_boost-streams --version 0.0.8
# Gemfile gem "turbo-rails", ">= 1.1", "< 2" gem "turbo_boost-streams", "~> 0.0.8"
-
Next, add the NPM package to your
package.json
file.yarn add @turbo-boost/streams@0.0.8
{ "dependencies": { "@hotwired/turbo-rails": ">=7.2", "@turbo-boost/streams": "^0.0.8" } }
config/importmap.rb
file.bin/importmap pin @turbo-boost/streams@0.0.8
# config/importmap.rb pin "@hotwired/turbo-rails", to: "https://ga.jspm.io/npm:@hotwired/turbo-rails@7.2.4/app/javascript/turbo/index.js" pin "@turbo-boost/streams", to: "https://ga.jspm.io/npm:@turbo-boost/streams@0.0.8/app/javascript/turbo_boost-streams.js"
-
Finally, configure your JavaScript application.
// app/javascript/application.js import '@hotwired/turbo-rails' import '@turbo-boost/streams'