1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
//! # JSON utilities for Rust.
//!
//! A collection of utilities for working with JSON in Rust.
//! Written for my own convenience, but feel free to use it.
//!
//! ## Features
//! - Read and write JSON files.
//! - Print JSON to the console.
//! - Error handling.

pub mod error;
pub mod file;
mod inner;
pub mod json;
pub mod print;
mod test;

/// Re-export `serde_json`.
pub use serde_json;

pub mod prelude {
    //! A prelude for the `json_utils` crate.
    //! This module contains the most commonly used items.
    pub use crate::{
        error::Error,
        file::{read_json, write_json},
        print::print_json,
    };
    pub use serde_json::Value;
}