# THIS FILE IS AUTOMATICALLY GENERATED BY CARGO
#
# When uploading crates to the registry Cargo will automatically
# "normalize" Cargo.toml files for maximal compatibility
# with all versions of Cargo and also rewrite `path` dependencies
# to registry (e.g., crates.io) dependencies.
#
# If you are reading this file be aware that the original Cargo.toml
# will likely look very different (and much more reasonable).
# See Cargo.toml.orig for the original contents.

[package]
edition = "2021"
rust-version = "1.77"
name = "ruvector-wasm"
version = "0.1.2"
authors = ["Ruvector Team"]
build = false
autolib = false
autobins = false
autoexamples = false
autotests = false
autobenches = false
description = "WASM bindings for Ruvector for browser deployment"
readme = "README.md"
license = "MIT"
repository = "https://github.com/ruvnet/ruvector"

[features]
collections = [
    "dep:ruvector-collections",
    "dep:ruvector-filter",
]
default = []
simd = ["ruvector-core/simd"]

[lib]
name = "ruvector_wasm"
crate-type = [
    "cdylib",
    "rlib",
]
path = "src/lib.rs"

[[test]]
name = "wasm"
path = "tests/wasm.rs"

[dependencies.anyhow]
version = "1.0"

[dependencies.console_error_panic_hook]
version = "0.1"

[dependencies.getrandom]
version = "0.3"
features = ["wasm_js"]

[dependencies.getrandom02]
version = "0.2"
features = ["js"]
package = "getrandom"

[dependencies.js-sys]
version = "0.3"

[dependencies.parking_lot]
version = "0.12"

[dependencies.ruvector-collections]
version = "0.1.2"
optional = true

[dependencies.ruvector-core]
version = "0.1.2"
features = [
    "memory-only",
    "uuid-support",
]
default-features = false

[dependencies.ruvector-filter]
version = "0.1.2"
optional = true

[dependencies.serde]
version = "1.0"
features = ["derive"]

[dependencies.serde-wasm-bindgen]
version = "0.6"

[dependencies.serde_json]
version = "1.0"

[dependencies.thiserror]
version = "2.0"

[dependencies.tracing-wasm]
version = "0.2"

[dependencies.wasm-bindgen]
version = "0.2"

[dependencies.wasm-bindgen-futures]
version = "0.4"

[dependencies.web-sys]
version = "0.3"
features = [
    "Worker",
    "MessagePort",
    "console",
    "console",
    "Window",
    "IdbDatabase",
    "IdbFactory",
    "IdbObjectStore",
    "IdbRequest",
    "IdbTransaction",
    "IdbOpenDbRequest",
]

[dev-dependencies.wasm-bindgen-test]
version = "0.3"

[target.'cfg(target_arch = "wasm32")'.dependencies.getrandom]
version = "0.3"
features = [
    "wasm_js",
    "wasm_js",
]

[profile.release]
opt-level = "z"
lto = true
codegen-units = 1
panic = "abort"

[profile.release.package."*"]
opt-level = "z"
