@@ -74,25 +74,25 @@ export default defineAddon({
74
74
run : ( { sv, typescript, options, kit } ) => {
75
75
const ext = typescript ? 'ts' : 'js' ;
76
76
77
- sv . dependency ( 'drizzle-orm' , '^0.33.0 ' ) ;
78
- sv . devDependency ( 'drizzle-kit' , '^0.22.0 ' ) ;
77
+ sv . dependency ( 'drizzle-orm' , '^0.38.4 ' ) ;
78
+ sv . devDependency ( 'drizzle-kit' , '^0.30.2 ' ) ;
79
79
80
80
// MySQL
81
- if ( options . mysql === 'mysql2' ) sv . dependency ( 'mysql2' , '^3.11 .0' ) ;
82
- if ( options . mysql === 'planetscale' ) sv . dependency ( '@planetscale/database' , '^1.18 .0' ) ;
81
+ if ( options . mysql === 'mysql2' ) sv . dependency ( 'mysql2' , '^3.12 .0' ) ;
82
+ if ( options . mysql === 'planetscale' ) sv . dependency ( '@planetscale/database' , '^1.19 .0' ) ;
83
83
84
84
// PostgreSQL
85
- if ( options . postgresql === 'neon' ) sv . dependency ( '@neondatabase/serverless' , '^0.9 .4' ) ;
86
- if ( options . postgresql === 'postgres.js' ) sv . dependency ( 'postgres' , '^3.4.4 ' ) ;
85
+ if ( options . postgresql === 'neon' ) sv . dependency ( '@neondatabase/serverless' , '^0.10 .4' ) ;
86
+ if ( options . postgresql === 'postgres.js' ) sv . dependency ( 'postgres' , '^3.4.5 ' ) ;
87
87
88
88
// SQLite
89
89
if ( options . sqlite === 'better-sqlite3' ) {
90
- sv . dependency ( 'better-sqlite3' , '^11.1.2 ' ) ;
91
- sv . devDependency ( '@types/better-sqlite3' , '^7.6.11 ' ) ;
90
+ sv . dependency ( 'better-sqlite3' , '^11.8.0 ' ) ;
91
+ sv . devDependency ( '@types/better-sqlite3' , '^7.6.12 ' ) ;
92
92
}
93
93
94
94
if ( options . sqlite === 'libsql' || options . sqlite === 'turso' )
95
- sv . dependency ( '@libsql/client' , '^0.9 .0' ) ;
95
+ sv . dependency ( '@libsql/client' , '^0.14 .0' ) ;
96
96
97
97
sv . file ( '.env' , ( content ) => generateEnvFileContent ( content , options ) ) ;
98
98
sv . file ( '.env.example' , ( content ) => generateEnvFileContent ( content , options ) ) ;
@@ -179,7 +179,6 @@ export default defineAddon({
179
179
const objExpression = exportDefault . arguments ?. [ 0 ] ;
180
180
if ( ! objExpression || objExpression . type !== 'ObjectExpression' ) return content ;
181
181
182
- const driver = options . sqlite === 'turso' ? common . createLiteral ( 'turso' ) : undefined ;
183
182
const authToken =
184
183
options . sqlite === 'turso'
185
184
? common . expressionFromString ( 'process.env.DATABASE_AUTH_TOKEN' )
@@ -192,12 +191,12 @@ export default defineAddon({
192
191
authToken
193
192
} ) ,
194
193
verbose : { type : 'BooleanLiteral' , value : true } ,
195
- strict : { type : 'BooleanLiteral' , value : true } ,
196
- driver
194
+ strict : { type : 'BooleanLiteral' , value : true }
197
195
} ) ;
198
196
197
+ const dialect = options . sqlite === 'turso' ? 'turso' : options . database ;
199
198
object . overrideProperties ( objExpression , {
200
- dialect : common . createLiteral ( options . database )
199
+ dialect : common . createLiteral ( dialect )
201
200
} ) ;
202
201
203
202
// The `driver` property is only required for _some_ sqlite DBs.
0 commit comments