Fresh Shopify Remix app template ships with a TypeScript error on first build
Developers initialising a new Shopify Remix app template encounter a TypeScript error in app/shopify.server.ts before writing any code. The error stems from npm installing two incompatible versions of @shopify/shopify-api — v12 pulled in by @shopify/shopify-app-session-storage-prisma@8 and v13 bundled with @shopify/shopify-app-remix@4. Because the version ranges do not overlap, TypeScript detects mismatched private property declarations between the two copies and refuses to compile. The fix is a one-line dependency upgrade — running npm install @shopify/shopify-app-session-storage-prisma@^9 aligns both packages to @shopify/shopify-api@^13, leaving a single version in node_modules and a clean TypeScript build. The same version conflict also explains why some open-source Shopify apps use workaround casts like 'as never' in billing code.
This is an AI-generated summary. ShortSingh links to the original source for the complete article.

Discussion (0)
Log in to join the discussion and vote.
Log in