json reflect type err
hyahm opened this issue · 2 comments
hyahm commented
{
"employees": [{
"firstName": "John",
"lastName": "Doe"
},
{
"firstName": "Anna",
"lastName": "Smith"
},
{
"firstName": "Peter",
"lastName": "Jones"
}
],
"name": {
"first": "Tom",
"last": "Hanks"
},
"age": 61.9,
"high": 175,
"iswoman": true,
"sgggg": "ajsdfjlj",
"nick": {
"first": "Tom",
"last": "Hanks"
}
}
JJ := gojsonq.New().JSONString(n).Get()
if reflect.ValueOf(v).Kind() == reflect.Float64 {
//jsonstruct[k] = v
//unmarshal(v)
base = true
jsonstruct[k] = v
}
get this high type is float64
only support map,slice,float64,string,bool ?
thedevsaddam commented
I'm not sure what is your question, if you are confused about the decoding then check this link
hyahm commented
encoding/json package only suport these types