From 52fba64cb2f77a58dc408f6a01719d0a026ee9c9 Mon Sep 17 00:00:00 2001 From: Chris Swithinbank Date: Thu, 7 Mar 2024 19:20:45 +0000 Subject: [PATCH] [ci] format --- packages/db/src/core/integration/index.ts | 2 +- packages/db/src/core/load-file.ts | 6 +++--- packages/db/src/core/types.ts | 2 +- .../db/test/fixtures/integrations/integration/config.ts | 2 +- packages/db/test/fixtures/integrations/integration/seed.ts | 2 +- .../db/test/fixtures/integrations/integration/shared.ts | 2 +- 6 files changed, 8 insertions(+), 8 deletions(-) diff --git a/packages/db/src/core/integration/index.ts b/packages/db/src/core/integration/index.ts index 26bcd393f7..557490213b 100644 --- a/packages/db/src/core/integration/index.ts +++ b/packages/db/src/core/integration/index.ts @@ -11,7 +11,7 @@ import { type ManagedAppToken, getManagedAppTokenOrExit } from '../tokens.js'; import { type VitePlugin, getDbDirectoryUrl } from '../utils.js'; import { fileURLIntegration } from './file-url.js'; import { typegen } from './typegen.js'; -import { type LateTables, vitePluginDb, type LateSeedFiles } from './vite-plugin-db.js'; +import { type LateSeedFiles, type LateTables, vitePluginDb } from './vite-plugin-db.js'; import { vitePluginInjectEnvTs } from './vite-plugin-inject-env-ts.js'; function astroDBIntegration(): AstroIntegration { diff --git a/packages/db/src/core/load-file.ts b/packages/db/src/core/load-file.ts index 987c0143d8..66a5e27c75 100644 --- a/packages/db/src/core/load-file.ts +++ b/packages/db/src/core/load-file.ts @@ -1,14 +1,14 @@ -import type { AstroConfig, AstroIntegration } from 'astro'; -import { build as esbuild } from 'esbuild'; import { existsSync } from 'node:fs'; import { unlink, writeFile } from 'node:fs/promises'; import { createRequire } from 'node:module'; import { fileURLToPath, pathToFileURL } from 'node:url'; +import type { AstroConfig, AstroIntegration } from 'astro'; +import { build as esbuild } from 'esbuild'; import { CONFIG_FILE_NAMES, VIRTUAL_MODULE_ID } from './consts.js'; import { INTEGRATION_TABLE_CONFLICT_ERROR } from './errors.js'; import { errorMap } from './integration/error-map.js'; import { getConfigVirtualModContents } from './integration/vite-plugin-db.js'; -import { dbConfigSchema, type AstroDbIntegration } from './types.js'; +import { type AstroDbIntegration, dbConfigSchema } from './types.js'; import { getDbDirectoryUrl } from './utils.js'; const isDbIntegration = (integration: AstroIntegration): integration is AstroDbIntegration => diff --git a/packages/db/src/core/types.ts b/packages/db/src/core/types.ts index 8d46cbfece..cff08c4a52 100644 --- a/packages/db/src/core/types.ts +++ b/packages/db/src/core/types.ts @@ -1,9 +1,9 @@ +import type { AstroIntegration } from 'astro'; import { SQL } from 'drizzle-orm'; import { SQLiteAsyncDialect } from 'drizzle-orm/sqlite-core'; import { type ZodTypeDef, z } from 'zod'; import { SERIALIZED_SQL_KEY, type SerializedSQL } from '../runtime/types.js'; import { errorMap } from './integration/error-map.js'; -import type { AstroIntegration } from 'astro'; export type MaybePromise = T | Promise; export type MaybeArray = T | T[]; diff --git a/packages/db/test/fixtures/integrations/integration/config.ts b/packages/db/test/fixtures/integrations/integration/config.ts index 00b8123c43..ecead779cd 100644 --- a/packages/db/test/fixtures/integrations/integration/config.ts +++ b/packages/db/test/fixtures/integrations/integration/config.ts @@ -1,5 +1,5 @@ -import { defineDB } from 'astro:db'; import { menu } from './shared'; +import { defineDB } from 'astro:db'; export default defineDB({ tables: { diff --git a/packages/db/test/fixtures/integrations/integration/seed.ts b/packages/db/test/fixtures/integrations/integration/seed.ts index cf10d66577..d46b05e1c1 100644 --- a/packages/db/test/fixtures/integrations/integration/seed.ts +++ b/packages/db/test/fixtures/integrations/integration/seed.ts @@ -1,6 +1,6 @@ import { asDrizzleTable } from '@astrojs/db/utils'; -import { db } from 'astro:db'; import { menu } from './shared'; +import { db } from 'astro:db'; export default async function () { const table = asDrizzleTable('menu', menu); diff --git a/packages/db/test/fixtures/integrations/integration/shared.ts b/packages/db/test/fixtures/integrations/integration/shared.ts index b4f5243de3..d46ae65a65 100644 --- a/packages/db/test/fixtures/integrations/integration/shared.ts +++ b/packages/db/test/fixtures/integrations/integration/shared.ts @@ -1,4 +1,4 @@ -import { defineTable, column } from 'astro:db'; +import { column, defineTable } from 'astro:db'; export const menu = defineTable({ columns: {