solid-primitives icon indicating copy to clipboard operation
solid-primitives copied to clipboard

[@solid-primitives/storage] error: Cannot resolve "@tauri-apps/plugin-store" from "node_modules/@solid-primitives/storage/dist/index.js" and externals are not allowed!

Open FlatMapIO opened this issue 1 year ago • 6 comments

Describe the bug

After updating to the latest @solid-primitives/storage, a build error occurred in solid-start.

Minimal Reproduction Link

NO

FlatMapIO avatar Apr 23 '24 07:04 FlatMapIO

Thanks for the information. I'll have a look.

atk avatar Apr 23 '24 11:04 atk

I cannot reproduce this, unfortunately. Are you using solid-start inside a tauri-v2 app? In that case, you need to install @tauri-apps/plugin-store. Otherwise, there should be no issue.

atk avatar Apr 23 '24 12:04 atk

I created a reproduction app, and I found that problems only occur when the vinxin preset is set to cloudflare-module.

FlatMapIO avatar Apr 23 '24 13:04 FlatMapIO

Ah, it could be that the cloudflare present attempts to package even potential dependencies like this one. Not sure how to address this. @davedbase, @thetarnav any ideas? If not, we could move the tauri-related primitives to a storage/tauri subfolder so the main module can be included without referencing it, but I would like to not need this slightly inconvenient solution if possible.

atk avatar Apr 23 '24 17:04 atk

I’m not a fan of any external dependencies too be honest, but if they are necessary a submodule sounds good, they need to be separated.

thetarnav avatar Apr 23 '24 17:04 thetarnav

Here we go: https://github.com/solidjs-community/solid-primitives/pull/621

atk avatar Apr 26 '24 11:04 atk