Skip to content

Commit

Permalink
fix: reference base types (#10315)
Browse files Browse the repository at this point in the history
* fix: reference root types

* chore: changeset

* chore: stray console log
  • Loading branch information
bholmesdev authored Mar 4, 2024
1 parent 6407897 commit 78ddfad
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 4 deletions.
5 changes: 5 additions & 0 deletions .changeset/giant-lions-dance.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@astrojs/db": patch
---

Fix type definitions for `astro:db`
5 changes: 2 additions & 3 deletions packages/db/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,12 +4,12 @@
"description": "",
"license": "MIT",
"type": "module",
"types": "./dist/index.d.ts",
"author": "withastro",
"types": "./index.d.ts",
"main": "./dist/index.js",
"exports": {
".": {
"types": "./dist/index.d.ts",
"types": "./index.d.ts",
"import": "./dist/index.js"
},
"./utils": {
Expand Down Expand Up @@ -51,7 +51,6 @@
},
"files": [
"index.d.ts",
"config-augment.d.ts",
"dist"
],
"keywords": [
Expand Down
1 change: 0 additions & 1 deletion packages/db/src/runtime/db-client.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@ const isWebContainer = !!process.versions?.webcontainer;

export function createLocalDatabaseClient({ dbUrl }: { dbUrl: string }): LibSQLDatabase {
const url = isWebContainer ? 'file:content.db' : dbUrl;
console.log('memory', process.env.TEST_IN_MEMORY_DB);
const client = createClient({ url: process.env.TEST_IN_MEMORY_DB ? ':memory:' : url });
const db = drizzleLibsql(client);

Expand Down

0 comments on commit 78ddfad

Please sign in to comment.