SolidJSS
SolidJS10mo ago
27 replies
ChrisThornham

Stuck On A Build Error

I've been stuck on the following build error all day.

⚙  Preparing app for node-server...
✔ Generated public .output/public                                                                           
ℹ Initializing prerenderer  
[vinxi] ℹ Building Nitro Server (preset: nitro-prerender, compatibility date: 2024-11-25)
"@revenuecat/purchases-capacitor" is imported by ".vinxi/build/server-fns/_server/assets/app-CtcriKcd.js", but could not be resolved – treating it as an external dependency.

[vinxi] ✔ Nitro Server built
[nitro] compiled: 0.021ms
[vinxi] ✔ You can preview this build using npx serve .output/public

 ERROR  nt.init is not a function

    at .vinxi/prerender/chunks/nitro/nitro.mjs:1551:14
    at ModuleJob.run (node:internal/modules/esm/module_job:273:25)
    at async onImport.tracePromise.__proto__ (node:internal/modules/esm/loader:600:26)
    at async prerender (node_modules/nitropack/dist/core/index.mjs:1892:44)
    at async createBuild (node_modules/vinxi/lib/build.js:376:2)
    at async Object.run (node_modules/vinxi/bin/cli.mjs:235:5)
    at async runCommand (node_modules/citty/dist/index.mjs:316:16)
    at async runCommand (node_modules/citty/dist/index.mjs:307:11)
    at async runMain (node_modules/citty/dist/index.mjs:445:7) 



 ERROR  nt.init is not a function


It looks like vinxi/nitro is trying to pre-render "@revenuecat/purchases-capacitor" but failing.

"@revenuecat/purchases-capacitor" is a client-side SDK. If Start is trying to render this on the server, that would be an issue.

That said, I have SSR set to
false
in app.config.ts.

Any help would be appreciated.

Happy to provide more context if needed.
Was this page helpful?