项目作者: otiai10

项目描述 :
Golang JSON Indent Encoder with io.Writer
高级语言: Go
项目地址: git://github.com/otiai10/jsonindent.git
创建时间: 2017-11-15T10:07:06Z
项目社区:https://github.com/otiai10/jsonindent

开源协议:

下载


JSON Indent for Go Just for Enjoying Code Golf :golf:

You Ain’t Gonna Need This

Because this is just a shorthand for json.Encoder.SetIndet.

  1. jsonindent.NewEncoder(w).Encode(v)
  2. // is equivalent to
  3. // encoder := json.NewEncoder(w)
  4. // encoder.SetIndent("", "\t")
  5. // encoder.Encode(v)

Build Status
GoDoc