create-absolutejs 0.5.0 → 0.6.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/data.d.ts +1 -1
- package/dist/data.js +2 -2
- package/dist/generators/configurations/generatePackageJson.d.ts +2 -2
- package/dist/generators/configurations/generatePackageJson.js +12 -4
- package/dist/generators/configurations/initializeRoot.js +2 -2
- package/dist/generators/db/generateDatabaseTypes.d.ts +3 -3
- package/dist/generators/db/generateDatabaseTypes.js +12 -7
- package/dist/generators/db/generateDrizzleSchema.d.ts +3 -3
- package/dist/generators/db/generateDrizzleSchema.js +4 -6
- package/dist/generators/db/generateSqliteSchema.d.ts +2 -2
- package/dist/generators/db/generateSqliteSchema.js +1 -1
- package/dist/generators/db/handlerTemplates.d.ts +40 -20
- package/dist/generators/db/handlerTemplates.js +131 -91
- package/dist/generators/db/scaffoldDatabase.d.ts +2 -2
- package/dist/generators/db/scaffoldDatabase.js +6 -6
- package/dist/generators/db/scaffoldDocker.d.ts +3 -3
- package/dist/generators/db/scaffoldDocker.js +2 -2
- package/dist/generators/html/scaffoldHTML.js +2 -2
- package/dist/generators/project/collectDependencies.d.ts +2 -2
- package/dist/generators/project/collectDependencies.js +2 -2
- package/dist/generators/project/generateAbsoluteAuthConfig.d.ts +2 -0
- package/dist/generators/project/generateAbsoluteAuthConfig.js +128 -0
- package/dist/generators/project/generateDBBlock.js +17 -10
- package/dist/generators/project/generateImportsBlock.d.ts +2 -2
- package/dist/generators/project/generateImportsBlock.js +28 -23
- package/dist/generators/project/generateRoutesBlock.d.ts +3 -3
- package/dist/generators/project/generateRoutesBlock.js +57 -46
- package/dist/generators/project/generateServer.d.ts +2 -2
- package/dist/generators/project/generateServer.js +28 -12
- package/dist/generators/project/scaffoldBackend.d.ts +6 -0
- package/dist/generators/project/scaffoldBackend.js +23 -0
- package/dist/generators/project/scaffoldFrontends.d.ts +2 -2
- package/dist/generators/project/scaffoldFrontends.js +18 -3
- package/dist/generators/react/generateReactComponents.d.ts +5 -0
- package/dist/generators/react/generateReactComponents.js +126 -0
- package/dist/generators/react/scaffoldReact.d.ts +1 -1
- package/dist/generators/react/scaffoldReact.js +11 -2
- package/dist/index.js +1 -1
- package/dist/messages.d.ts +1 -1
- package/dist/messages.js +5 -4
- package/dist/prompt.js +4 -3
- package/dist/questions/authOption.d.ts +1 -0
- package/dist/questions/{authProvider.js → authOption.js} +5 -5
- package/dist/questions/databaseHost.js +12 -0
- package/dist/scaffold.d.ts +1 -1
- package/dist/scaffold.js +13 -9
- package/dist/templates/assets/svg/google-logo.svg +7 -0
- package/dist/templates/react/components/OAuthLink.tsx +39 -0
- package/dist/templates/react/components/ProfilePicture.tsx +56 -0
- package/dist/templates/styles/tailwind.css +1 -0
- package/dist/typeGuards.d.ts +2 -2
- package/dist/typeGuards.js +1 -1
- package/dist/types.d.ts +7 -2
- package/dist/utils/abort.js +1 -1
- package/dist/utils/parseCommandLineOptions.js +30 -9
- package/dist/utils/t3-utils.js +1 -1
- package/package.json +2 -1
- package/dist/generators/project/generateUseBlock.d.ts +0 -6
- package/dist/generators/project/generateUseBlock.js +0 -32
- package/dist/generators/react/generateReactPage.d.ts +0 -2
- package/dist/generators/react/generateReactPage.js +0 -23
- package/dist/questions/authProvider.d.ts +0 -1
- package/dist/templates/react/pages/ReactExample.tsx +0 -18
package/dist/data.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import type { FrontendLabels, AvailableDependency } from './types';
|
|
2
2
|
export declare const availableFrontends: readonly ["react", "html", "svelte", "vue", "htmx"];
|
|
3
|
-
export declare const availableAuthProviders: readonly ["
|
|
3
|
+
export declare const availableAuthProviders: readonly ["abs", "none"];
|
|
4
4
|
export declare const availableDrizzleDialects: readonly ["gel", "mysql", "postgresql", "sqlite", "singlestore", "mariadb"];
|
|
5
5
|
export declare const availablePrismaDialects: readonly ["mysql", "postgresql", "sqlite", "mongodb", "mariadb", "cockroachdb", "mssql"];
|
|
6
6
|
export declare const availableDatabaseEngines: readonly ["postgresql", "mysql", "sqlite", "mongodb", "mariadb", "gel", "singlestore", "cockroachdb", "mssql", "none"];
|
package/dist/data.js
CHANGED
|
@@ -7,7 +7,7 @@ export const availableFrontends = [
|
|
|
7
7
|
'vue',
|
|
8
8
|
'htmx'
|
|
9
9
|
];
|
|
10
|
-
export const availableAuthProviders = ['
|
|
10
|
+
export const availableAuthProviders = ['abs', 'none'];
|
|
11
11
|
export const availableDrizzleDialects = [
|
|
12
12
|
'gel',
|
|
13
13
|
'mysql',
|
|
@@ -86,7 +86,7 @@ export const absoluteAuthPlugin = {
|
|
|
86
86
|
packageName: 'absoluteAuth'
|
|
87
87
|
}
|
|
88
88
|
],
|
|
89
|
-
latestVersion: '0.
|
|
89
|
+
latestVersion: '0.21.1',
|
|
90
90
|
value: '@absolutejs/auth'
|
|
91
91
|
};
|
|
92
92
|
export const scopedStatePlugin = {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import type { CreateConfiguration } from '../../types';
|
|
2
|
-
type CreatePackageJsonProps = Pick<CreateConfiguration, '
|
|
2
|
+
type CreatePackageJsonProps = Pick<CreateConfiguration, 'authOption' | 'useTailwind' | 'databaseEngine' | 'databaseHost' | 'plugins' | 'orm' | 'frontendDirectories' | 'codeQualityTool'> & {
|
|
3
3
|
projectName: string;
|
|
4
4
|
latest: boolean;
|
|
5
5
|
};
|
|
6
|
-
export declare const createPackageJson: ({ projectName,
|
|
6
|
+
export declare const createPackageJson: ({ projectName, authOption, plugins, databaseEngine, orm, databaseHost, useTailwind, latest, frontendDirectories, codeQualityTool }: CreatePackageJsonProps) => void;
|
|
7
7
|
export {};
|
|
@@ -36,7 +36,7 @@ const dbScripts = {
|
|
|
36
36
|
waitCmd: initTemplates.singlestore.wait
|
|
37
37
|
}
|
|
38
38
|
};
|
|
39
|
-
export const createPackageJson = ({ projectName,
|
|
39
|
+
export const createPackageJson = ({ projectName, authOption, plugins, databaseEngine, orm, databaseHost, useTailwind, latest, frontendDirectories, codeQualityTool }) => {
|
|
40
40
|
const s = spinner();
|
|
41
41
|
if (latest)
|
|
42
42
|
s.start('Resolving package versions…');
|
|
@@ -51,7 +51,7 @@ export const createPackageJson = ({ projectName, authProvider, plugins, database
|
|
|
51
51
|
for (const dep of defaultDependencies) {
|
|
52
52
|
dependencies[dep.value] = resolveVersion(dep.value, dep.latestVersion);
|
|
53
53
|
}
|
|
54
|
-
if (
|
|
54
|
+
if (authOption === 'abs') {
|
|
55
55
|
dependencies[absoluteAuthPlugin.value] = resolveVersion(absoluteAuthPlugin.value, absoluteAuthPlugin.latestVersion);
|
|
56
56
|
}
|
|
57
57
|
for (const pluginValue of plugins) {
|
|
@@ -72,7 +72,7 @@ export const createPackageJson = ({ projectName, authProvider, plugins, database
|
|
|
72
72
|
devDependencies['@tailwindcss/cli'] = resolveVersion('@tailwindcss/cli', '4.1.7');
|
|
73
73
|
}
|
|
74
74
|
if (flags.requiresReact) {
|
|
75
|
-
dependencies['react'] = resolveVersion('react', '19.2.
|
|
75
|
+
dependencies['react'] = resolveVersion('react', '19.2.1');
|
|
76
76
|
devDependencies['@types/react'] = resolveVersion('@types/react', '19.2.0');
|
|
77
77
|
}
|
|
78
78
|
if (flags.requiresReact && codeQualityTool === 'eslint+prettier') {
|
|
@@ -100,7 +100,7 @@ export const createPackageJson = ({ projectName, authProvider, plugins, database
|
|
|
100
100
|
dependencies['@neondatabase/serverless'] = resolveVersion('@neondatabase/serverless', '1.0.0');
|
|
101
101
|
break;
|
|
102
102
|
case 'planetscale':
|
|
103
|
-
dependencies['@planetscale/database'] = resolveVersion('@planetscale/database', '1.
|
|
103
|
+
dependencies['@planetscale/database'] = resolveVersion('@planetscale/database', '1.19.0');
|
|
104
104
|
break;
|
|
105
105
|
case 'turso':
|
|
106
106
|
dependencies['@libsql/client'] = resolveVersion('@libsql/client', '0.15.9');
|
|
@@ -143,6 +143,10 @@ export const createPackageJson = ({ projectName, authProvider, plugins, database
|
|
|
143
143
|
if (isLocal && databaseEngine === 'singlestore') {
|
|
144
144
|
dependencies['mysql2'] = resolveVersion('mysql2', '3.14.2');
|
|
145
145
|
}
|
|
146
|
+
if (databaseEngine === 'postgresql' && databaseHost === 'planetscale') {
|
|
147
|
+
dependencies['pg'] = resolveVersion('pg', '8.11.0');
|
|
148
|
+
devDependencies['@types/pg'] = resolveVersion('@types/pg', '8.6.1');
|
|
149
|
+
}
|
|
146
150
|
if (isLocal && databaseEngine === 'mssql') {
|
|
147
151
|
dependencies['mssql'] = resolveVersion('mssql', '12.1.0');
|
|
148
152
|
devDependencies['@types/mssql'] = resolveVersion('@types/mssql', '9.1.8');
|
|
@@ -154,6 +158,10 @@ export const createPackageJson = ({ projectName, authProvider, plugins, database
|
|
|
154
158
|
scripts['db:sqlite'] = 'sqlite3 db/database.sqlite';
|
|
155
159
|
scripts['db:init'] = 'sqlite3 db/database.sqlite < db/init.sql';
|
|
156
160
|
}
|
|
161
|
+
if (orm === 'drizzle') {
|
|
162
|
+
scripts['db:studio'] = 'drizzle-kit studio';
|
|
163
|
+
scripts['db:push'] = 'drizzle-kit push';
|
|
164
|
+
}
|
|
157
165
|
const packageJson = {
|
|
158
166
|
dependencies,
|
|
159
167
|
devDependencies,
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { copyFileSync, existsSync, mkdirSync } from '
|
|
2
|
-
import { join } from '
|
|
1
|
+
import { copyFileSync, existsSync, mkdirSync } from 'fs';
|
|
2
|
+
import { join } from 'path';
|
|
3
3
|
export const initalizeRoot = (projectName, templatesDirectory) => {
|
|
4
4
|
if (existsSync(projectName)) {
|
|
5
5
|
throw new Error(`Cannot create project "${projectName}": directory already exists.`);
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { AuthOption, DatabaseEngine, DatabaseHost } from '../../types';
|
|
2
2
|
type GenerateTypesProps = {
|
|
3
3
|
databaseEngine: DatabaseEngine;
|
|
4
4
|
databaseHost: DatabaseHost;
|
|
5
|
-
|
|
5
|
+
authOption: AuthOption;
|
|
6
6
|
};
|
|
7
|
-
export declare const generateDatabaseTypes: ({ databaseEngine, databaseHost,
|
|
7
|
+
export declare const generateDatabaseTypes: ({ databaseEngine, databaseHost, authOption }: GenerateTypesProps) => string;
|
|
8
8
|
export {};
|
|
@@ -1,16 +1,21 @@
|
|
|
1
1
|
import { isDrizzleDialect } from '../../typeGuards';
|
|
2
|
-
export const generateDatabaseTypes = ({ databaseEngine, databaseHost,
|
|
2
|
+
export const generateDatabaseTypes = ({ databaseEngine, databaseHost, authOption }) => {
|
|
3
3
|
let dbImport = '';
|
|
4
4
|
let dbTypeLine = '';
|
|
5
5
|
if (databaseHost === 'neon') {
|
|
6
6
|
dbImport = `import { NeonHttpDatabase } from 'drizzle-orm/neon-http';`;
|
|
7
7
|
dbTypeLine = 'export type DatabaseType = NeonHttpDatabase<SchemaType>;';
|
|
8
8
|
}
|
|
9
|
-
else if (databaseHost === 'planetscale') {
|
|
9
|
+
else if (databaseHost === 'planetscale' && databaseEngine === 'mysql') {
|
|
10
10
|
dbImport = `import { PlanetScaleDatabase } from 'drizzle-orm/planetscale-serverless';`;
|
|
11
11
|
dbTypeLine =
|
|
12
12
|
'export type DatabaseType = PlanetScaleDatabase<SchemaType>;';
|
|
13
13
|
}
|
|
14
|
+
else if (databaseHost === 'planetscale' &&
|
|
15
|
+
databaseEngine === 'postgresql') {
|
|
16
|
+
dbImport = `import { NodePgDatabase } from 'drizzle-orm/node-postgres';`;
|
|
17
|
+
dbTypeLine = 'export type DatabaseType = NodePgDatabase<SchemaType>;';
|
|
18
|
+
}
|
|
14
19
|
else if (databaseHost === 'turso') {
|
|
15
20
|
dbImport = `import { LibSQLDatabase } from 'drizzle-orm/libsql';`;
|
|
16
21
|
dbTypeLine = 'export type DatabaseType = LibSQLDatabase<SchemaType>;';
|
|
@@ -46,10 +51,10 @@ export const generateDatabaseTypes = ({ databaseEngine, databaseHost, authProvid
|
|
|
46
51
|
break;
|
|
47
52
|
}
|
|
48
53
|
}
|
|
49
|
-
const schemaImport =
|
|
50
|
-
? `import { users,
|
|
51
|
-
: `import { countHistory
|
|
52
|
-
const extraTypes =
|
|
54
|
+
const schemaImport = authOption === 'abs'
|
|
55
|
+
? `import { users, schema } from '../../db/schema';`
|
|
56
|
+
: `import { countHistory } from '../../db/schema';`;
|
|
57
|
+
const extraTypes = authOption === 'abs'
|
|
53
58
|
? `export type User = typeof users.$inferSelect;
|
|
54
59
|
export type NewUser = typeof users.$inferInsert;`
|
|
55
60
|
: `export type CountHistory = typeof countHistory.$inferSelect;
|
|
@@ -57,6 +62,6 @@ export type NewCountHistory = typeof countHistory.$inferInsert;`;
|
|
|
57
62
|
return `${schemaImport}
|
|
58
63
|
${dbImport}
|
|
59
64
|
|
|
60
|
-
${
|
|
65
|
+
${`${dbTypeLine}\n`}export type SchemaType = typeof schema;\n\n${extraTypes}
|
|
61
66
|
`;
|
|
62
67
|
};
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { AuthOption, AvailableDrizzleDialect } from '../../types';
|
|
2
2
|
type GenerateSchemaProps = {
|
|
3
3
|
databaseEngine: AvailableDrizzleDialect;
|
|
4
|
-
|
|
4
|
+
authOption: AuthOption;
|
|
5
5
|
};
|
|
6
|
-
export declare const generateDrizzleSchema: ({ databaseEngine,
|
|
6
|
+
export declare const generateDrizzleSchema: ({ databaseEngine, authOption }: GenerateSchemaProps) => string;
|
|
7
7
|
export {};
|
|
@@ -49,7 +49,7 @@ const DIALECTS = {
|
|
|
49
49
|
}
|
|
50
50
|
};
|
|
51
51
|
const builder = (expr) => expr.split('(')[0];
|
|
52
|
-
export const generateDrizzleSchema = ({ databaseEngine,
|
|
52
|
+
export const generateDrizzleSchema = ({ databaseEngine, authOption }) => {
|
|
53
53
|
const cfg = DIALECTS[databaseEngine];
|
|
54
54
|
const intBuilder = databaseEngine === 'mysql' ||
|
|
55
55
|
databaseEngine === 'singlestore' ||
|
|
@@ -59,7 +59,7 @@ export const generateDrizzleSchema = ({ databaseEngine, authProvider }) => {
|
|
|
59
59
|
const timeBuilder = builder(cfg.time);
|
|
60
60
|
const jsonBuilder = builder(cfg.json);
|
|
61
61
|
const stringBuilder = builder(cfg.string);
|
|
62
|
-
const importBuilders =
|
|
62
|
+
const importBuilders = authOption === 'abs'
|
|
63
63
|
? [cfg.table, stringBuilder, timeBuilder, jsonBuilder]
|
|
64
64
|
: [cfg.table, intBuilder, timeBuilder];
|
|
65
65
|
const uniqueBuilders = Array.from(new Set(importBuilders));
|
|
@@ -86,7 +86,7 @@ const MILLIS_PER_DAY = 86400000;\n\n`
|
|
|
86
86
|
const timestampColumn = databaseEngine === 'sqlite'
|
|
87
87
|
? `${cfg.time}.notNull().default(sql\`(julianday('now') - \${JULIAN_DAY_UNIX_EPOCH_OFFSET}) * \${MILLIS_PER_DAY}\`)`
|
|
88
88
|
: `${cfg.time}.notNull().defaultNow()`;
|
|
89
|
-
const tableBlock =
|
|
89
|
+
const tableBlock = authOption === 'abs'
|
|
90
90
|
? `export const users = ${cfg.table}('users', {
|
|
91
91
|
auth_sub: ${cfg.string}.primaryKey(),
|
|
92
92
|
created_at: ${timestampColumn},
|
|
@@ -97,7 +97,7 @@ const MILLIS_PER_DAY = 86400000;\n\n`
|
|
|
97
97
|
count: ${intBuilder}('count').notNull(),
|
|
98
98
|
created_at: ${timestampColumn}
|
|
99
99
|
});`;
|
|
100
|
-
const schemaKey =
|
|
100
|
+
const schemaKey = authOption === 'abs' ? 'users' : 'countHistory';
|
|
101
101
|
return `
|
|
102
102
|
${sqliteImports}${builderImport}
|
|
103
103
|
|
|
@@ -106,7 +106,5 @@ ${constsBlock}${tableBlock}
|
|
|
106
106
|
export const schema = {
|
|
107
107
|
${schemaKey}
|
|
108
108
|
};
|
|
109
|
-
|
|
110
|
-
export type SchemaType = typeof schema;
|
|
111
109
|
`;
|
|
112
110
|
};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import {
|
|
2
|
-
export declare const generateSqliteSchema: (
|
|
1
|
+
import { AuthOption } from '../../types';
|
|
2
|
+
export declare const generateSqliteSchema: (authOption: AuthOption) => "CREATE TABLE IF NOT EXISTS users (\n auth_sub TEXT PRIMARY KEY,\n created_at INTEGER NOT NULL DEFAULT ((julianday('now') - 2440587.5) * 86400000),\n metadata TEXT DEFAULT '{}'\n);" | "CREATE TABLE IF NOT EXISTS count_history (\n uid INTEGER PRIMARY KEY AUTOINCREMENT,\n count INTEGER NOT NULL,\n created_at INTEGER NOT NULL DEFAULT ((julianday('now') - 2440587.5) * 86400000)\n);";
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export const generateSqliteSchema = (
|
|
1
|
+
export const generateSqliteSchema = (authOption) => authOption && authOption !== 'none'
|
|
2
2
|
? `CREATE TABLE IF NOT EXISTS users (
|
|
3
3
|
auth_sub TEXT PRIMARY KEY,
|
|
4
4
|
created_at INTEGER NOT NULL DEFAULT ((julianday('now') - 2440587.5) * 86400000),
|
|
@@ -7,97 +7,117 @@ type QueryOperations = {
|
|
|
7
7
|
declare const driverConfigurations: {
|
|
8
8
|
readonly 'cockroachdb:sql:local': {
|
|
9
9
|
readonly dbType: "SQL";
|
|
10
|
-
readonly importLines: "
|
|
10
|
+
readonly importLines: "";
|
|
11
11
|
readonly queries: QueryOperations;
|
|
12
12
|
};
|
|
13
13
|
readonly 'gel:drizzle:local': {
|
|
14
14
|
readonly dbType: "GelJsDatabase<SchemaType>";
|
|
15
|
-
readonly importLines: "
|
|
15
|
+
readonly importLines: "import { eq } from 'drizzle-orm'\nimport { schema } from '../../../db/schema'\n";
|
|
16
16
|
readonly queries: QueryOperations;
|
|
17
17
|
};
|
|
18
18
|
readonly 'gel:sql:local': {
|
|
19
19
|
readonly dbType: "Client";
|
|
20
|
-
readonly importLines: "
|
|
20
|
+
readonly importLines: "";
|
|
21
21
|
readonly queries: QueryOperations;
|
|
22
22
|
};
|
|
23
23
|
readonly 'mariadb:drizzle:local': {
|
|
24
24
|
readonly dbType: "MySql2Database<SchemaType>";
|
|
25
|
-
readonly importLines: "
|
|
25
|
+
readonly importLines: "import { eq } from 'drizzle-orm'\nimport { schema } from '../../../db/schema'";
|
|
26
26
|
readonly queries: QueryOperations;
|
|
27
27
|
};
|
|
28
28
|
readonly 'mariadb:sql:local': {
|
|
29
29
|
readonly dbType: "SQL";
|
|
30
|
-
readonly importLines: "
|
|
30
|
+
readonly importLines: "";
|
|
31
31
|
readonly queries: QueryOperations;
|
|
32
32
|
};
|
|
33
33
|
readonly 'mongodb:native:local': {
|
|
34
34
|
readonly dbType: "Db";
|
|
35
|
-
readonly importLines: "
|
|
35
|
+
readonly importLines: "";
|
|
36
36
|
readonly queries: QueryOperations;
|
|
37
37
|
};
|
|
38
38
|
readonly 'mssql:sql:local': {
|
|
39
39
|
readonly dbType: "ConnectionPool";
|
|
40
|
-
readonly importLines: "
|
|
40
|
+
readonly importLines: "";
|
|
41
41
|
readonly queries: QueryOperations;
|
|
42
42
|
};
|
|
43
43
|
readonly 'mysql:drizzle:local': {
|
|
44
44
|
readonly dbType: "MySql2Database<SchemaType>";
|
|
45
|
-
readonly importLines: "
|
|
45
|
+
readonly importLines: "import { eq } from 'drizzle-orm'\nimport { schema } from '../../../db/schema'";
|
|
46
|
+
readonly queries: QueryOperations;
|
|
47
|
+
};
|
|
48
|
+
readonly 'mysql:drizzle:planetscale': {
|
|
49
|
+
readonly dbType: "PlanetScaleDatabase<SchemaType>";
|
|
50
|
+
readonly importLines: "import { eq } from 'drizzle-orm'\nimport { schema } from '../../../db/schema'";
|
|
46
51
|
readonly queries: QueryOperations;
|
|
47
52
|
};
|
|
48
53
|
readonly 'mysql:sql:local': {
|
|
49
54
|
readonly dbType: "SQL";
|
|
50
|
-
readonly importLines: "
|
|
55
|
+
readonly importLines: "";
|
|
56
|
+
readonly queries: QueryOperations;
|
|
57
|
+
};
|
|
58
|
+
readonly 'mysql:sql:planetscale': {
|
|
59
|
+
readonly dbType: "Client";
|
|
60
|
+
readonly importLines: "";
|
|
51
61
|
readonly queries: QueryOperations;
|
|
52
62
|
};
|
|
53
63
|
readonly 'postgresql:drizzle:local': {
|
|
54
64
|
readonly dbType: "BunSQLDatabase<SchemaType>";
|
|
55
|
-
readonly importLines: "
|
|
65
|
+
readonly importLines: "import { eq } from 'drizzle-orm'\nimport { schema } from '../../../db/schema'";
|
|
56
66
|
readonly queries: QueryOperations;
|
|
57
67
|
};
|
|
58
68
|
readonly 'postgresql:drizzle:neon': {
|
|
59
69
|
readonly dbType: "NeonDatabase<SchemaType>";
|
|
60
|
-
readonly importLines: "
|
|
70
|
+
readonly importLines: "import { eq } from 'drizzle-orm'\nimport { schema } from '../../../db/schema'";
|
|
71
|
+
readonly queries: QueryOperations;
|
|
72
|
+
};
|
|
73
|
+
readonly 'postgresql:drizzle:planetscale': {
|
|
74
|
+
readonly dbType: "NodePgDatabase<SchemaType>";
|
|
75
|
+
readonly importLines: "import { eq } from 'drizzle-orm'\nimport { schema } from '../../../db/schema'";
|
|
61
76
|
readonly queries: QueryOperations;
|
|
62
77
|
};
|
|
63
78
|
readonly 'postgresql:sql:local': {
|
|
64
79
|
readonly dbType: "SQL";
|
|
65
|
-
readonly importLines: "
|
|
80
|
+
readonly importLines: "";
|
|
66
81
|
readonly queries: QueryOperations;
|
|
67
82
|
};
|
|
68
83
|
readonly 'postgresql:sql:neon': {
|
|
69
84
|
readonly dbType: "Pool";
|
|
70
|
-
readonly importLines: "
|
|
85
|
+
readonly importLines: "";
|
|
71
86
|
readonly queries: QueryOperations;
|
|
72
87
|
};
|
|
73
|
-
readonly '
|
|
88
|
+
readonly 'postgresql:sql:planetscale': {
|
|
74
89
|
readonly dbType: "Pool";
|
|
75
|
-
readonly importLines: "
|
|
90
|
+
readonly importLines: "";
|
|
76
91
|
readonly queries: QueryOperations;
|
|
77
92
|
};
|
|
78
93
|
readonly 'singlestore:drizzle:local': {
|
|
79
94
|
readonly dbType: "SingleStoreDriverDatabase<SchemaType>";
|
|
80
|
-
readonly importLines: "
|
|
95
|
+
readonly importLines: "import { eq } from 'drizzle-orm'\nimport { schema } from '../../../db/schema'";
|
|
96
|
+
readonly queries: QueryOperations;
|
|
97
|
+
};
|
|
98
|
+
readonly 'singlestore:sql:local': {
|
|
99
|
+
readonly dbType: "Pool";
|
|
100
|
+
readonly importLines: "import { RowDataPacket } from 'mysql2/promise'\n";
|
|
81
101
|
readonly queries: QueryOperations;
|
|
82
102
|
};
|
|
83
103
|
readonly 'sqlite:drizzle:local': {
|
|
84
104
|
readonly dbType: "BunSQLiteDatabase<SchemaType>";
|
|
85
|
-
readonly importLines: "
|
|
105
|
+
readonly importLines: "import { eq } from 'drizzle-orm'\nimport { schema } from '../../../db/schema'";
|
|
86
106
|
readonly queries: QueryOperations;
|
|
87
107
|
};
|
|
88
108
|
readonly 'sqlite:drizzle:turso': {
|
|
89
109
|
readonly dbType: "LibSQLDatabase<SchemaType>";
|
|
90
|
-
readonly importLines: "
|
|
110
|
+
readonly importLines: "import { eq } from 'drizzle-orm'\nimport { schema } from '../../../db/schema'";
|
|
91
111
|
readonly queries: QueryOperations;
|
|
92
112
|
};
|
|
93
113
|
readonly 'sqlite:sql:local': {
|
|
94
114
|
readonly dbType: "Database";
|
|
95
|
-
readonly importLines: "
|
|
115
|
+
readonly importLines: "";
|
|
96
116
|
readonly queries: QueryOperations;
|
|
97
117
|
};
|
|
98
118
|
readonly 'sqlite:sql:turso': {
|
|
99
119
|
readonly dbType: "Client";
|
|
100
|
-
readonly importLines: "
|
|
120
|
+
readonly importLines: "";
|
|
101
121
|
readonly queries: QueryOperations;
|
|
102
122
|
};
|
|
103
123
|
};
|