Disable extension loading for wasm

We should enable it later when wasm become more mature
This commit is contained in:
Diego Reis
2025-07-28 14:46:10 -03:00
parent 9de48c3926
commit bab10909c3
11 changed files with 23 additions and 2975 deletions

View File

@@ -189,9 +189,12 @@ impl Database {
#[napi]
pub fn load_extension(&self, path: String) -> napi::Result<()> {
let ext_path = turso_core::resolve_ext_path(path.as_str()).map_err(into_napi_error)?;
self.conn
.load_extension(ext_path)
.map_err(into_napi_error)?;
#[cfg(not(target_family = "wasm"))]
{
self.conn
.load_extension(ext_path)
.map_err(into_napi_error)?;
}
Ok(())
}