notifications aren't showing up correctly at custom livewire layout
Continue the topic that was created on #notifications channel...
I'm using a custom livewire layout to show public pages besides admin panel, I realize that when I configure my layout that way that is in the image, the notifications works as it should, but keep warning me at console that Alpine JS has already been loaded...and if I take out the
manifest.js
from the layout, notifications doesnt work at all...24 Replies
So you probably imported
Alpine
in app.js
? And it's probably also added via @stack
or @livewireScripts
Filament
Installation - Notifications - Filament
Elegant TALL stack notifications for Laravel artisans.
Yepp I follow the docs, not sure If that's the right way since I already use notifications in admin panel? 🤔
What is
manifest.js
doing? I think I remember that was a thing with Laravel Mix?What's in
app.js
& manifest.js
?
What are you using to compile the assets, I see that you are including it using the asset()
helper instead of the mix/vite helperThe
app.js
I'm pretty sure that is importing AlpineFloatingUI
, Alpine
and NotificationsAlpinePlugin
just as said the docs...about the manifest.js
I'm not sure, I think this file was created on some other process since I'm using Laravel Mix to compile my assets. Then I realized that the admin panel was loading this file and then I tried to use it in my layout and it works
If I use just the app.js
but inside the <body> tag, the notifications persist with that weird behaviour that it's being called, the network request it's happening and successfull, but it doesn't show the notification in my blade page, still invisible...can you send app.js
and manifest.js
I just have the
manifest.js
compiled...that's why I'm not sure if I should use it in my livewire layout, I just put it there to test since my admin panel is loading this file..mix file
what is manifest though
whats in it
so you just imported a random js file into your layout?
i want to know whats in it
i cant read compiled js code
I just have the manifest.js compiled...that's why I'm not sure if I should use it in my livewire layout, I just put it there to test since my admin panel is loading this file..
compiled from what
i dont understand
Well, as I said, filament admin panel is loading this file and I put this just to test if I'm missing something that this
manifest
file has that my app.js
it doesnt...I just had followed the notifications docs to install it in my livewire layout, forget about the manifest
since this file doesnt exist in the docs guide..I think it's the webpack loader stuff that Laravel Mix puts in a separate file
thats a .json file?
this is a compiled .js file
Nope. That’s another thing:
https://webpack.js.org/concepts/manifest/
webpack
The Manifest | webpack
ive never seen this generated
I think you need to configure it. Not sure why the OP has this file though
Unknown User•2y ago
Message Not Public
Sign In & Join Server To View
Solved by migrating from Laravel Mix to Vite.