Releases: DallasHoff/sqlocal
Releases · DallasHoff/sqlocal
0.11.1
0.11.0
- The
transaction
method has been reworked with a new implementation. Its new API allows running arbitrary logic between the SQL queries executed as part of a transaction while still ensuring that the transaction is atomic and isolated. - The
SQLocalKysely
dialect has been modified so that Kysely'stransaction
method uses SQLocal's new transaction functionality, which allows it to ensure isolation of transactions run using it. - A warning has been added to the
SQLocalDrizzle
driver that is logged when using Drizzle'stransaction
method since that method cannot ensure the transaction's isolation. It recommends using SQLocal'stransaction
method instead, as documented here. - The previous implementation of the
transaction
method is now namedbatch
.
0.10.2
- The
SQLocal
constructor can now accept an object with additional options to define the behavior of the client. For now, this includes 2 new options:readOnly
andverbose
- The
sql
method can now be called with a plain string if needed (e.g.sql('SELECT * FROM foo')
), instead of as a tagged template - The
sql
method's type parameter was changed to represent one record in the query result (extends Record<string, any>
), instead of an array of results (extends Record<string, any>[]
), and a matching type parameter was added to thetransaction
method to allow assertion of the return type of queries
0.10.1
- The file returned by
getDatabaseFile
now has the MIME typeapplication/x-sqlite3
, instead of an empty MIME type - Fix
getDatabaseFile
failing for databases not stored at the root of the origin private file system
0.10.0
- Add
getDatabaseInfo
method - The
destroy
method now executesPRAGMA optimize
on the database before closing the connection - In a future update, the
transaction
method will be reworked, and the current version of the method will be namedbatch
. This update adds abatch
method that is an alias oftransaction
.
0.9.0
- Add
createScalarFunction
method
0.8.0
- Add
batchDriver
toSQLocalDrizzle
to support Drizzle's Batch API transaction
method now returns any result records from queries it executes
0.7.1
kysely
is now a peer dependency instead of a direct dependency, allowing anykysely
version to be installed alongside SQLocal
0.7.0
- Fix
overwriteDatabaseFile
not working in Safari
0.6.4
No significant changes