Json2V icon indicating copy to clipboard operation
Json2V copied to clipboard

Convert a json to a struct in Vlang

Json2V

A more complex real json that I got and tested was this one -> CNPJ brasilapi

Converts a json into a structure in Vlang.

The generated code can have sums of types, structs and Any{}(empty)

  • [X] Key and value simple.
  • [X] SumTypes for array with multiple types.
  • [X] New structures for each object key.
  • [X] Reserved word with _ or @.
  • [X] Omitempty.
  • [X] Structs anonymous.
  • [X] Property name replacement.



Start of the project



screenshot



Second stage



screenshot



End of project



screenshot


Stack utilizada

Front-end: pico.css, lodash

Icon: favicon

Code editor: ace

fonts: google fonts