# struct use MarshalIndent
dataByte, err := json.MarshalIndent(v, "", " ")
# str json use gjson @pretty
gjson.Get(task.Config, "@pretty").String()
golang pretty-print json
Beer Home2024-07-27 13:03
相关推荐
LeoCrawls16 小时前
Python 读取 JSON 常见报错排查,附完整处理函数EatFan18 小时前
Go语言全栈实战:基于 Gin + Vue + JWT + RBAC 从零搭建前后端分离权限管理系统ZealSinger18 小时前
Go slog生产落地LevelVar与共存丹宇码农19 小时前
Go 与 Python 协程(Coroutine)对比演示项目ttwuai19 小时前
Go开源后台管理系统推荐:3个官方仓库怎么按技术栈和适用边界比较?茉莉玫瑰花茶21 小时前
GO [ 并发 · 调度器 ]恋喵大鲤鱼21 小时前
go list command茉莉玫瑰花茶1 天前
GO [ 方法 ]星河耀银海1 天前
数据解析:AI返回JSON数据在HTML5中的渲染方法三8442 天前
Fastjson 漏洞 · 01 · 认识 Fastjson 与序列化基础