Playing around with SVG

This commit is contained in:
2017-07-07 02:07:34 +02:00
parent 137a2270df
commit 567e8e63d1
7 changed files with 153 additions and 0 deletions

9
utils/ToJSON.go Normal file
View File

@ -0,0 +1,9 @@
package utils
import "encoding/json"
// ToJSON converts an object to a JSON string, ignoring errors.
func ToJSON(v interface{}) string {
str, _ := json.Marshal(v)
return string(str)
}