aleclarson / vite-tsconfig-paths

Support for TypeScript's path mapping in Vite
MIT License
1.28k stars 45 forks source link

Breaks with vite-ssg on vercel build #31

Closed appinteractive closed 2 years ago

appinteractive commented 3 years ago

Running build localy works great, but when pushing to vercel it breaks.

00:18:34.586    vite v2.4.1 building SSR bundle for production... 
00:18:34.633     > node_modules/vite-tsconfig-paths/dist/index.js:103:40: error: [plugin: vite:dep-scan] viteResolve is not a function
lukasluecke commented 3 years ago

I have the same issue - not sure how to reproduce it locally either :/

Have switched to manual alias definitions for now, but would prefer to use this plugin.

cuibonobo commented 3 years ago

Also seeing this same error on Cloudflare Pages on Node 14.

jamesknelson commented 2 years ago

Having this issue too. It turns out it's possible to reproduce it locally by deleting the node_modules/.vite directory.

Running vite dev to recreate the directory fixes the issue, and then removing it again makes the issue return.

aleclarson commented 2 years ago

Fixed in v3.3.14