-
-
Notifications
You must be signed in to change notification settings - Fork 131
[2.x] Production build not working in Vite projects #69
Comments
There is a workaround! Add this to your Vite config: inertiajs-tables-laravel-query-builder/app/vite.config.js Lines 7 to 11 in 5208595
It increases the size of the
|
I don't know if it's related, but I had to add :inertia=$inertia to the Table tag:
I'm using Vite. |
dear @pascalbaljet can you try with vite vertion 3 ? |
I can confirm that with vite 3 I don't have this issue |
I tagged a new npm package (v2.1) which works correctly with Vite 3. The demo has also been updated to Vite 3. |
Hello @pascalbaljet, Projects with Laravel mix won't work anymore after the latest version released? |
Hello, |
When using the library in a Laravel project that uses Vite, you'll find this error in the browser console:
currentRenderingInstance is null
. The test suite, a regular Laravel app with Laravel Mix, uses Webpack and works fine.From searching the web, it seems the library is using the wrong Vue instance (at least not the one from the app). On the other hand, it looks like the Vite config is set up correctly.
inertiajs-tables-laravel-query-builder/vite.config.js
Line 20 in e8c38d1
From inspecting the build manually, I can see Vue is not included in the library, which is good.
Any help would be appreciated!
The text was updated successfully, but these errors were encountered: