Module: Ruact::Controller
- Extended by:
- ActiveSupport::Concern
- Defined in:
- lib/ruact/controller.rb
Overview
Include in ApplicationController to enable RSC rendering.
class ApplicationController < ActionController::Base
include Ruact::Controller
end
After that, any action whose view is a .html.erb file will automatically:
-
Respond to text/x-component requests with a raw Flight payload
-
Respond to text/html requests with an HTML shell + inline Flight payload