Sha256: 22de6745f67ba30f93a8c3f2942e5a8d8116fe92e6bc6162834c2787bc0b751b
Contents?: true
Size: 594 Bytes
Versions: 39
Compression:
Stored size: 594 Bytes
Contents
# NOTE: This is a workaround to get Devise working with Turbo class TurboDeviseController < ApplicationController class Responder < ActionController::Responder def to_turbo_stream controller.render(options.merge(formats: :html)) rescue ActionView::MissingTemplate => error if get? raise error elsif has_errors? && default_action render rendering_options.merge(formats: :html, status: :unprocessable_entity) else redirect_to navigation_location end end end self.responder = Responder respond_to :html, :turbo_stream end
Version data entries
39 entries across 39 versions & 1 rubygems