neondatabase / serverless

Connect to Neon PostgreSQL from serverless/worker/edge functions
https://www.npmjs.com/package/@neondatabase/serverless
MIT License
318 stars 11 forks source link

Bundle ESM from scratch instead of wrapping CJS #55

Closed amitdahan closed 6 months ago

amitdahan commented 6 months ago

Closes #54

I noticed gen-esm-wrapper was generating a correct import mod from './index.js import, which SHOULD work, but according to #54 (which reproduces) it doesn't seem to do the trick for some reason.

I thought a separate ESM bundle would be generally better and it seemed to do the trick for the above issue's repro.

If there's anything else I can & should test - lmk!