API reference › @evolu/sqlite-wasm › c-api › sqlite3_auto_extension
function sqlite3_auto_extension(
deps: SqliteWasmDep,
): (xEntryPoint: SqliteFunctionPtr) => SqliteResultCode;
Defined in: packages/sqlite-wasm/src/CApi.ts:876
Registers an entry point that SQLite calls for every new connection, where an
error it returns fails the open; registering one twice is a no-op. Despite
the void (*)(void) prototype SQLite calls it as int xEntryPoint(sqlite3 *db, char **pzErrMsg, const sqlite3_api_routines *pThunk), so its function
table entry must have that type.
Wasm type i(i). Signature ["sqlite3_auto_extension", "int", "funcptr:i(ppp)"] from Evolu's supplement: SQLite binds the auto-extension
functions by hand to manage the JavaScript functions it converts.