3 unstable releases

0.1.3 Jun 29, 2025
0.1.2 Dec 24, 2023
0.1.1 Dec 24, 2023
0.1.0 Dec 24, 2023
0.0.0 Dec 24, 2023

#1664 in Parser implementations

Download history 12/week @ 2025-07-09 22/week @ 2025-07-16 1/week @ 2025-07-23 75/week @ 2025-07-30 32/week @ 2025-08-20 138/week @ 2025-08-27 2/week @ 2025-09-03 120/week @ 2025-10-01 14/week @ 2025-10-15 10/week @ 2025-10-22

144 downloads per month
Used in rxdc

Apache-2.0

8KB
166 lines

json2lua

Convert JSON to Lua table

Example:

use json2lua::parse;

let json = r#"{
  "string": "json2lua",
  "int": 420,
  "bool": true,
  "null": null
}"#;

let lua = parse(json).unwrap();
// Output:
// {
//   ["string"] = "json2lua",
//   ["int"] = 420,
//   ["bool"] = true,
//   ["null"] = nil,
// }

Made with <3 by Dervex


json2lua

Convert JSON to Lua table

Version badge Downloads badge License badge Docs badge

Example:

use json2lua::parse;

let json = r#"{
  "string": "abc",
  "int": 123,
  "bool": true,
  "null": null
}"#;

let lua = parse(json).unwrap();
// Output:
// {
//   ["string"] = "abc",
//   ["int"] = 123,
//   ["bool"] = true,
//   ["null"] = nil,
// }

Dependencies

~1.4–2.5MB
~49K SLoC