8:34:16 PM webpack.1 | Version: webpack 4.44.2
8:34:16 PM webpack.1 | Time: 3899ms
8:34:16 PM webpack.1 | Built at: 10/25/2020 8:34:15 PM
8:34:16 PM webpack.1 | Asset Size Chunks Chunk Names
8:34:16 PM webpack.1 | application-141aa79e56d42feb82ca.js 986 KiB application [emitted] [immutable] application
8:34:16 PM webpack.1 | application-141aa79e56d42feb82ca.js.map 1.02 MiB application [emitted] [dev] application
8:34:16 PM webpack.1 | client-141aa79e56d42feb82ca.js 654 KiB client [emitted] [immutable] client
8:34:16 PM webpack.1 | client-141aa79e56d42feb82ca.js.map 674 KiB client [emitted] [dev] client
8:34:16 PM webpack.1 | manifest.json 832 bytes [emitted]
8:34:16 PM webpack.1 | media/images/banner-5f539d39241aceb17c07bbaa6e611cac.svg 16.2 KiB [emitted]
8:34:16 PM webpack.1 | media/images/icon-03960d2ed0f0c47a77a9fbf21ddf798f.svg 2.71 KiB [emitted]
8:34:16 PM webpack.1 | ERROR in ./node_modules/@inertiajs/inertia-svelte/src/index.js
8:34:16 PM webpack.1 | Module not found: Error: [CaseSensitivePathsPlugin] `/Users/jason/Projects/gateway/node_modules/@inertiajs/inertia-svelte/src/link.svelte` does not match the corresponding path on disk `Link.svelte`.
8:34:16 PM webpack.1 | ℹ 「wdm」: Failed to compile.
I followed the instructions in the Inertia docs, and couldn't get past this issue. I believe it has to do with webpack being confused while loading both Link.svelte and link.js. My app has a fairly vanilla setup, but I will try to reproduce it in a empty rails app.
Here's a minimal example app that demonstrates the problem:
https://github.com/ambethia/sit-demo/blob/master/app/javascript/packs/application.js
All I did was generate the app, install svelte and inertia with a simple model/controller.
I also have this issue. My temporary solution is rewrite these line
export { default as inertia } from './link' in node_modules/@inertiajs/inertia-svelte/src/index.js
to
export { default as inertia } from './link.js'
Oh, thanks @norazlan!
In version 0.6.0 of @inertia/inertia-svelte the problem still exists, when are you going to fix this?
This should be fixed in #529, which we hope to release soon. 👍
Most helpful comment
I also have this issue. My temporary solution is rewrite these line
export { default as inertia } from './link'innode_modules/@inertiajs/inertia-svelte/src/index.jsto
export { default as inertia } from './link.js'