Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Import session instead of reading window.Turbo.session #1094

Merged

Commits on Dec 1, 2023

  1. Import session instead of reading window.Turbo.session

    Follow-up to [hotwired#1049][]
    Follow-up to [hotwired#1073][]
    Related to [hotwired#1078][]
    
    Replace an internal `window.Turbo.session` access with an `import {
    session }` statement.
    
    Prior attempts at this change introduced circular dependencies. This
    attempt does not. Additionally, this change maintains the ability for
    consumers to access StreamActions through `window.Turbo.StreamActions`,
    while also enabling `import { StreamActions } from "@hotwired/turbo"`
    (or `from "@hotwired/turbo-rails"`).
    
    [hotwired#1049]: hotwired#1049
    [hotwired#1073]: hotwired#1073
    [hotwired#1078]: hotwired#1078
    seanpdoyle committed Dec 1, 2023
    Configuration menu
    Copy the full SHA
    7a7c6e2 View commit details
    Browse the repository at this point in the history