[package]
name = "fallow-types"
version.workspace = true
edition.workspace = true
license.workspace = true
repository.workspace = true
homepage.workspace = true
documentation.workspace = true
keywords.workspace = true
categories.workspace = true
description = "Shared types and serde paths for fallow codebase intelligence"
readme = "../../README.md"

[dependencies]
# Serialization
serde = { workspace = true }

# AST spans (for ExportInfo, ImportInfo, etc.)
oxc_span = { workspace = true }

# Cache serialization (for MemberAccess)
bitcode = { workspace = true }

# JSON Schema generation for the public JSON output contract.
# Gated by the `schema` feature so consumers (fallow-graph, fallow-extract,
# fallow-core, fallow-cli, fallow-napi) do not pay the schemars compile cost
# unless they explicitly opt in (only the schema-emit binary needs it).
schemars = { workspace = true, optional = true }
# `serde_json` carries the free-form rule-object payload on
# `AddToConfigValue::RuleObject` in the `output` module. The module is no
# longer feature-gated (typed action wrappers in `output_dead_code` use
# `IssueAction` at runtime), so `serde_json` ships unconditionally.
serde_json = { workspace = true }

[features]
# Adds `#[derive(schemars::JsonSchema)]` to result and extract types so the
# JSON output schema can be regenerated from the Rust source of truth.
schema = ["dep:schemars"]

[dev-dependencies]
serde_json = { workspace = true }
proptest = { workspace = true }

[lints]
workspace = true
