dpgen2 icon indicating copy to clipboard operation
dpgen2 copied to clipboard

Inpurt script switches to json5 format

Open wanghan-iapcm opened this issue 3 years ago • 2 comments

The json5 format is a extension of the json format, and is more human readable and easier to write. The main advantages:

  • support comments
  • trailing commas allowed.
  • no quotation needed for keys.

More details are found on the official web site of json5

The json5 is parsed by python package pyjson5

wanghan-iapcm avatar Oct 26 '22 12:10 wanghan-iapcm

I think YAML is good enough for most cases. If people feel that writing yaml/json directly is annoy, they could just write some Typescript script to generate YAML/JSON file. There are even modern solutions like cue-lang to validate and generate YAML configuration. Both Typescript and cue-lang are working well with VsCode if you define the type schema properly.

link89 avatar Feb 27 '23 06:02 link89

I think YAML is good enough for most cases.

I agree with it as YAML is also a superset of JSON and also supports all of these features (comments, no quotation, etc). However, it seems to me that dpgen2 has not supported YAML yet.

njzjz avatar Sep 16 '24 19:09 njzjz