# 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.70"
name = "hedl-wasm"
version = "2.0.0"
authors = ["marcflp <marc@dweve.com>"]
build = false
include = [
    "Cargo.toml",
    "README.md",
    "LICENSE",
    "NOTICE",
    "CHANGELOG*",
    "src/**",
    "tests/**",
    "benches/**",
    "examples/**",
]
publish = true
autolib = false
autobins = false
autoexamples = false
autotests = false
autobenches = false
description = "WebAssembly bindings for HEDL with TypeScript support"
homepage = "https://dweve.com"
documentation = "https://docs.rs/hedl-wasm"
readme = "README.md"
keywords = [
    "hedl",
    "data-format",
    "serialization",
    "parser",
    "token-efficient",
]
categories = [
    "encoding",
    "parser-implementations",
    "data-structures",
]
license = "Apache-2.0"
repository = "https://github.com/dweve-ai/hedl"

[package.metadata.docs.rs]
all-features = true
rustdoc-args = [
    "--cfg",
    "docsrs",
]

[package.metadata.wasm-pack.profile.release]
wasm-opt = false

[badges.maintenance]
status = "actively-developed"

[features]
all-formats = [
    "json",
    "yaml",
    "xml",
    "csv",
    "toon",
]
csv = ["dep:hedl-csv"]
default = ["json"]
full = [
    "json",
    "yaml",
    "xml",
    "csv",
    "toon",
]
full-validation = []
json = ["dep:hedl-json"]
minimal = []
query-api = []
standard = ["json"]
statistics = ["json"]
token-tools = []
toon = ["dep:hedl-toon"]
xml = ["dep:hedl-xml"]
yaml = ["dep:hedl-yaml"]

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

[[example]]
name = "token_estimation_demo"
path = "examples/token_estimation_demo.rs"

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

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

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

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

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

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

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

[dependencies.console_error_panic_hook]
version = "0.1"

[dependencies.hedl-c14n]
version = "2.0.0"

[dependencies.hedl-core]
version = "2.0.0"

[dependencies.hedl-csv]
version = "2.0.0"
optional = true

[dependencies.hedl-json]
version = "2.0.0"
optional = true

[dependencies.hedl-lint]
version = "2.0.0"

[dependencies.hedl-toon]
version = "2.0.0"
optional = true

[dependencies.hedl-xml]
version = "2.0.0"
optional = true

[dependencies.hedl-yaml]
version = "2.0.0"
optional = true

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

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

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

[dependencies.serde_json]
version = "1.0"

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

[dependencies.web-sys]
version = "0.3"
features = ["console"]

[target.'cfg(target_arch = "wasm32")'.dev-dependencies.wasm-bindgen-test]
version = "0.3"

[lints.clippy]
all = "warn"

[lints.rust]
unused_must_use = "allow"
warnings = "warn"

[lints.rust.rust_2018_idioms]
level = "warn"
priority = -1

[lints.rust.unexpected_cfgs]
level = "warn"
priority = 0
check-cfg = ["cfg(loom)"]
