dart / 1 / dart-convert / json-constant.html

JSON constant

JSON = const JsonCodec()

An instance of the default implementation of the JsonCodec.

This instance provides a convenient access to the most common JSON use cases.

Examples:

var encoded = JSON.encode([1, 2, { "a": null }]);
var decoded = JSON.decode('["foo", { "bar": 499 }]');

© 2012 the Dart project authors
Licensed under the Creative Commons Attribution-ShareAlike License v4.0.
https://api.dartlang.org/stable/1.24.3/dart-convert/JSON-constant.html