jard 1.0.1
jard: ^1.0.1 copied to clipboard
Package for json encode and decode.
Using #
This package is used for encoding and decoding JSON.
At the moment, encoding has been implemented, faster than using jsonEncode
from dart:convert.
Encode #
Encoding is available using the static encode
method of the Jard
class.
Usage example:
import 'package:jard/jard.dart';
void main() {
final map = <String, dynamic>{
'name': 'Alex',
'age': 22,
};
final json = Jard.encode(map);
print(json);
}
Expected output:
{"name":"Alex","age":22}
Decode #
Under development.
Performance #
Encode perfomance #
Execution time (microseconds) benchmark in JIT:
![](https://raw.githubusercontent.com/GlebBatykov/jard/main/doc/images/time-jit.jpg)
Execution time (microseconds) benchmark in AOT:
![](https://raw.githubusercontent.com/GlebBatykov/jard/main/doc/images/time-aot.jpg)
Memory costs do not differ, they are at the level of 1% error in various tests in the direction of Jard or dart:convert.