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

Laravel 10 - Method Illuminate\View\ComponentAttributeBag::all does not exist #1385

Closed
3 tasks done
scottzirkel opened this issue Mar 24, 2025 · 2 comments · Fixed by #1386
Closed
3 tasks done

Laravel 10 - Method Illuminate\View\ComponentAttributeBag::all does not exist #1385

scottzirkel opened this issue Mar 24, 2025 · 2 comments · Fixed by #1386

Comments

@scottzirkel
Copy link
Contributor

Flux version

v2.1.1

Livewire version

v3.5.19

Tailwind version

v4.0.9

Browser and Operating System

Safari on macOS

What is the problem?

Laravel 10 does not have an all method on the ComponentAttributeBag

This is a similar issue to #620

Image

Code snippets

In my case, it was triggered by the profile component:

<flux:profile
    class="cursor-pointer"
    initials="SZ"
/>

How do you expect it to work?

I believe changing FluxManager at line 127 from $attributes->all() to $attributes->getAttributes() should solve the issue.

I will have a PR incoming.

Please confirm (incomplete submissions will not be addressed)

  • I have provided easy and step-by-step instructions to reproduce the bug.
  • I have provided code samples as text and NOT images.
  • I understand my bug report will be closed if I haven't met the criteria above.
@bridgeyuwa
Copy link

bridgeyuwa commented Mar 25, 2025

But $attributes->getAttributes()does not include modifications ( merge() except() only() ) .
Won't this create other issues also?

@scottzirkel
Copy link
Contributor Author

The only place this is currently used is in a foreach loop on the above line. I updated it in my project and spent the rest of the day working with no other issues.

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 a pull request may close this issue.

2 participants