toon_x_json 0.0.3 copy "toon_x_json: ^0.0.3" to clipboard
toon_x_json: ^0.0.3 copied to clipboard

TOON <--> JSON, TOON- A compact JSON format

example/example.dart

import '../lib/toon_x_json.dart';
import 'json_formatter.dart';

void main() {
  // Example: Simple JSON with array of objects (tabular format)
  final data = {
    'users': [
      {'id': 1, 'name': 'Alice', 'role': 'admin'},
      {'id': 2, 'name': 'Bob', 'role': 'user'}
    ]
  };

  final toon = encode(data);
  print('=== Simple JSON Example ===');
  print(toon);
  print('');
  
  // Decode it back
  final decoded = decode(toon);
  print('Decoded JSON:');
  printJson(decoded);
}
4
likes
130
points
79
downloads

Publisher

unverified uploader

Weekly Downloads

TOON <--> JSON, TOON- A compact JSON format

Documentation

API reference

License

MIT (license)

More

Packages that depend on toon_x_json