1340691923@qq.com ebbf4120bf 第一次提交
2022-01-26 16:40:50 +08:00

16 lines
288 B
Go

package util
import (
jsoniter "github.com/json-iterator/go"
)
func IsJson(str string) bool {
maps := make(map[string]interface{})
var json = jsoniter.ConfigCompatibleWithStandardLibrary
err := json.Unmarshal(Str2bytes(str), &maps)
if err != nil {
return false
}
return true
}