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

Adds Turbo Interceptor to add X-Socket-Id header on Turbo requests #348

Merged
merged 1 commit into from
Jul 25, 2022

Conversation

tonysm
Copy link
Contributor

@tonysm tonysm commented Jul 25, 2022

Added

  • Adds a request interceptor to add the X-Socket-Id header to all Turbo requests by listening to the turbo:before-fetch-request event (docs)

@tonysm
Copy link
Contributor Author

tonysm commented Jul 25, 2022

I've been using this in my Turbo demo app for a while, thought it was be a good piece to submit to upstream. One caveat: the Turbo object must be imported and bound to the window object before Echo is initialized.

@taylorotwell taylorotwell merged commit d7706e0 into laravel:master Jul 25, 2022
@tonysm tonysm deleted the feature/turbo-interceptor branch July 25, 2022 14:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants