Skip to content

Commit 18f122a

Browse files
authored
Update README.md
1 parent 45b15f9 commit 18f122a

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

README.md

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,9 @@
44
[![crates.io](https://img.shields.io/crates/v/jsonpath_rs.svg)](https://crates.io/crates/jsonpath_rs)
55

66
# jsonpath_rs
7+
[![Forum](https://img.shields.io/badge/Forum-RedisJSON-blue)](https://forum.redislabs.com/c/modules/redisjson)
8+
[![Discord](https://img.shields.io/discord/697882427875393627?style=flat-square)](https://discord.gg/QUkjSsk)
9+
710
A JSONPath library for rust. The idea behind this library is that it can operate on any json representation as long as it implements the [`SelectValue`](src/select_value.rs) triat. The library has an implementation for [serde_json value](https://docs.serde.rs/serde_json/value/enum.Value.html) and [ivalue](https://docs.rs/tch/0.1.1/tch/enum.IValue.html).
811

912
### Getting Started
@@ -22,7 +25,7 @@ extern crate jsonpath_rs
2225

2326
fn main() {
2427
let mut query = jsonpath_rs::compile("$..friends[0]");
25-
let calculator = jsonpath_rs::create(&query)
28+
let path = jsonpath_rs::create(&query)
2629

2730
let json_obj = json!({
2831
"school": {
@@ -37,7 +40,7 @@ fn main() {
3740
]
3841
});
3942

40-
let json = calculator.calc(&json_obj);
43+
let json = path.calc(&json_obj);
4144

4245
assert_eq!(json, vec![
4346
&json!({"name": "foo3", "age": 30}),

0 commit comments

Comments
 (0)