(eventName string, tsTypesMap map[reflect.Type]string)
| 44 | } |
| 45 | |
| 46 | func getWaveEventDataTSType(eventName string, tsTypesMap map[reflect.Type]string) string { |
| 47 | rtype, found := WaveEventDataTypes[eventName] |
| 48 | if !found { |
| 49 | return "any" |
| 50 | } |
| 51 | if rtype == nil { |
| 52 | return "null" |
| 53 | } |
| 54 | tsType, _ := TypeToTSType(rtype, tsTypesMap) |
| 55 | if tsType == "" { |
| 56 | return "any" |
| 57 | } |
| 58 | return tsType |
| 59 | } |
| 60 | |
| 61 | func GenerateWaveEventTypes(tsTypesMap map[reflect.Type]string) string { |
| 62 | for _, rtype := range WaveEventDataTypes { |