DEV Community

Discussion on: Using Vite with Inertia — Laravel, Vue & Tailwind

Collapse
mitchazj profile image
Mitchell Johnson

Probably too late for this answer to be directly useful but answering in case anyone else is googling: unless you have to support older browsers (IE11 for example) then it's safe to just delete the import from your app.js file.

The import is only there to add polyfill support for es6 modules and I suspect vite removed it.
If you need it back, take a look at the legacy plugin: github.com/vitejs/vite/tree/main/p...

You'll have to reconfigure the import, and change some settings depending on your specific support needs.
But if you don't need to support legacy browsers, easiest fix is just delete the line and don't worry about it :)