tursodatabase / libsql-client-ts

TypeScript/JavaScript client API for libSQL
https://docs.turso.tech/sdk/ts/quickstart
MIT License
226 stars 32 forks source link

Override the default import for supported edge runtimes #65

Closed honzasp closed 1 year ago

honzasp commented 1 year ago

The default import had included the Node.js-specific local sqlite3 client, so all developers on platforms other than Node.js needed to use a subpackage import such as @libsql/client/web.

This PR adds conditional imports to package.json that should allow the default import @libsql/client to work as @libsql/client/web in the edge runtimes that we support.

Fixes #55