-
-
Notifications
You must be signed in to change notification settings - Fork 2.6k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix: move db ambient types to separate module (#10340)
* fix: move ambient types to separate modue * chore: changeset
- Loading branch information
1 parent
038201f
commit a60861c
Showing
4 changed files
with
16 additions
and
5 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
--- | ||
"@astrojs/db": patch | ||
--- | ||
|
||
Ensure `astro:db` types exist in your `db/config.ts` before running type generation. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,3 @@ | ||
export { default, cli } from './dist/index.js'; | ||
import './virtual.js'; | ||
|
||
declare module 'astro:db' { | ||
export { defineTable, defineDB, column, sql, NOW, TRUE, FALSE } from './dist/index.js'; | ||
} | ||
export { default, cli } from './dist/index.js'; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,3 @@ | ||
export type { ResolvedCollectionConfig, TableConfig } from './core/types.js'; | ||
export { cli } from './core/cli/index.js'; | ||
export { integration as default } from './core/integration/index.js'; | ||
export { sql, NOW, TRUE, FALSE, defineDB, defineTable, column } from './runtime/config.js'; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
declare module 'astro:db' { | ||
export const sql: typeof import('./dist/runtime/config.js').sql; | ||
export const NOW: typeof import('./dist/runtime/config.js').NOW; | ||
export const TRUE: typeof import('./dist/runtime/config.js').TRUE; | ||
export const FALSE: typeof import('./dist/runtime/config.js').FALSE; | ||
export const column: typeof import('./dist/runtime/config.js').column; | ||
export const defineDB: typeof import('./dist/runtime/config.js').defineDB; | ||
export const defineTable: typeof import('./dist/runtime/config.js').defineTable; | ||
} |