[package] authors = ["LongYinan "] edition = "2021" name = "napi-examples" publish = false version = "0.1.0" [lib] crate-type = ["cdylib"] [features] snmalloc = ["snmalloc-rs"] [dependencies] chrono = "0.4" futures = "0.3" napi-derive = { path = "../../crates/macro", features = ["type-def"] } napi-shared = { path = "../napi-shared" } serde = "1" serde_derive = "1" serde_json = "1" [target.'cfg(not(target_family = "wasm"))'.dependencies] napi = { path = "../../crates/napi", default-features = false, features = [ "napi9", "serde-json", "experimental", "latin1", "chrono_date", "tokio", "async", "tokio_rt", "tokio_fs", "tokio_macros", "deferred_trace", ] } tokio = { version = "1", features = ["rt", "time"] } [target.'cfg(target_family = "wasm")'.dependencies] napi = { path = "../../crates/napi", default-features = false, features = [ "napi9", "serde-json", "experimental", "latin1", "chrono_date", "tokio", "async", "tokio_rt", "tokio_macros", "tokio_sync", "deferred_trace", ] } tokio = { version = "1", default-features = false, features = ["rt", "time"] } [dependencies.snmalloc-rs] version = "0.3" features = ["build_cc", "local_dynamic_tls"] optional = true [build-dependencies] napi-build = { path = "../../crates/build" } [dev-dependencies] trybuild = "1.0"