📜  Flutter 解析 json - Javascript 代码示例

📅  最后修改于: 2022-03-11 15:02:01.310000             🧑  作者: Mango

代码示例3
import 'dart:convert';

main() {
  String nestedObjText =
      '{"title": "Dart Tutorial", "description": "Way to parse Json", "author": {"name": "bezkoder", "age": 30}}';

  Tutorial tutorial = Tutorial.fromJson(jsonDecode(nestedObjText));

  print(tutorial);