[package]
name = "reovim-client-model"
version.workspace = true
edition.workspace = true
authors.workspace = true
license.workspace = true
description = "Common client model for Reovim (platform-agnostic abstractions)"
repository.workspace = true
keywords = ["reovim", "editor", "client"]
categories = ["text-editors"]

[lib]
crate-type = ["cdylib", "rlib"]

[lints]
workspace = true

[dependencies]
serde = { version = "1.0", features = ["derive"] }
serde_json = "1.0"

# WASM-specific (feature-gated)
wasm-bindgen = { version = "0.2", optional = true }
tsify-next = { version = "0.5", optional = true, features = ["js"] }
js-sys = { version = "0.3", optional = true }
console_error_panic_hook = { version = "0.1", optional = true }

[features]
default = []
# FFI support for Android/iOS
ffi = []
# WASM support for web client
wasm = ["dep:wasm-bindgen", "dep:tsify-next", "dep:js-sys", "dep:console_error_panic_hook"]
