Failed to build with Vite plugin and Vercel adapter.
Hi all, I'm trying to deploy my app to Vercel. I've had no luck so far (I can see the project files on Vercel's directory listing no matter what I change).
I then came across the
solid-start-vercel
package which provides an adapter for the vite config, hoping it might work.
The current vite config is as follows:
However, when I try to build with bun run build
(or npm), I get the following error: "[commonjs--resolver] Missing "./dist/types/collapsible" specifier in "@kobalte/core" package".
However, if I remove the solid()
function from the config, it builds correctly.
I am actually using solid-ui which is then using kobalte as a dependency. All packages and dependencies are at their latest version.
Thanks in advance.16 Replies
Okay, I was being very stupid.
I had an import to that folder, somehow, which I was not even using.
I just tried to deploy it now to Vercel, but the same directory listing error occurs (it's a 404 NOT_FOUND) error. Not sure how to make it work.
don't think u need the
solid-start-vercel
with the new solid start https://start.solidjs.com/api/viteSolidStart Beta Documentation
SolidStart Beta Documentation
Early release documentation and resources for SolidStart Beta
Maybe you need to specify
noExternals
as well as mentioned here https://kobalte.dev/docs/core/overview/ssrHi @bigmistqke, @albie.
I tried both of those, but still not working. I also tried both with
plugins: [solid()]
, but same outcomeStill shows the same error:
The vercel deployment config is set to SolidStart and the build outputs a
.output
and .vinxi
folder, like it should, so I'm not sure why Vercel is not deploying it correctly.This is the Vercel output source:
Which version of solid are you using?
Might be easier if I send my whole package.json:
I got it to work using vinxi build —preset vercel
But actions are not working properly with SSR, still trying to understand why.
I'll try that now, thanks
I think that in your vite configuration you don’t need neither solid nor the vercel adapter
well, that did something different at least 😅
oh, i remember this error:
SyntaxError: The requested module 'seroval' does not provide an export named 'createStream'
There are two seroval folders created (2 different versions) as shown when the app is built.which is causing a conflict
well that's fun...