Skip to content

Improve json formatting to improve readability #147

@Tisten

Description

@Tisten

When I compared dl to cap'n'proto, and the most striking thing cap'n'proto was better at was the awesome json formatting:
Example cap'n'proto:

    {"ptr": {"graphComponent": {"graph": {
      "nodes": [
        {"type": "tm_tick_event", "label": "", "positionX": -537.10931396484375, "positionY": -14.238007545471191, "settings": {"ptr": {}}},
        {"type": "tm_mixer_play_wav", "label": "", "positionX": -332.38427734375, "positionY": -171.35000610351562, "settings": {"ptr": {}}},
        {"type": "tm_mixer_set_pitch", "label": "", "positionX": 679.589111328125, "positionY": -23.874832153320312, "settings": {"ptr": {}}},
        {"type": "tm_vec3_length", "label": "", "positionX": -124.12257385253906, "positionY": 122.64999389648438, "settings": {"ptr": {}}},

And the same in dl:

      }, {
        "GraphComponent" : "ptr_488"
      }, {
...
        "ptr_488" : {
          "Graph" : "ptr_496"
        },
...
        "ptr_496" : {
          "Nodes" : [
          {
              "Type" : "tm_tick_event",
              "Label" : null,
              "PositionX" : -537.109314,
              "PositionY" : -14.2380075,
              "Width" : 0,
              "Settings" : {
                "AimConstraint" : null
              }
            }, {
              "Type" : "tm_mixer_play_wav",
              "Label" : null,
              "PositionX" : -332.384277,
              "PositionY" : -171.350006,
              "Width" : 0,
              "Settings" : {
                "AimConstraint" : null
              }
            }, {
              "Type" : "tm_mixer_set_pitch",
              "Label" : null,
              "PositionX" : 679.589111,
              "PositionY" : -23.8748322,
              "Width" : 0,
              "Settings" : {
                "AimConstraint" : null
              }
            }, {
              "Type" : "tm_vec3_length",
              "Label" : null,
              "PositionX" : -124.122574,
              "PositionY" : 122.649994,
              "Width" : 0,
              "Settings" : {
                "AimConstraint" : null
              }

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions