qruto / laravel-wave

Painless Laravel Broadcasting with SSE

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

[Bug]: Vite exception for the new laravel npm module setup

GoodM4ven opened this issue · comments

What happened?

Your package is among a lot of packages that got affected by the new module type in packages.json:
https://github.com/laravel/laravel/blob/84991f23011dfde4bc3ae3db04343c3afb3bc122/package.json#LL3C22-L3C22

Laravel-Wave now throws this exception:

Uncaught SyntaxError: The requested module '/node_modules/.vite/deps/laravel-wave.js?v=f42660d9' does not provide an export named 'default' (at echo.js:9:8)

How to reproduce the bug

Just install it in a new Laravel project, I guess?!

Package Version

^0.7.1

PHP Version

8.1.7

Laravel Version

10.13.5

Which operating systems does with happen with?

Linux

Notes

I'm using the TALL stack. (blade preset with Laravel Breeze)

Try to use named import:

import { Wave } from "laravel-wave"

I will adopt the docs. Thanks for your attention 👍