Documentation ¶
Index ¶
- Constants
- func ColonPad(text string, length int) string
- func GetKeyForValue(data map[string]string, val string) string
- func IsFileValid(file string) error
- func JSONNumberToInt(number json.Number) int64
- func JSONNumberToString(number json.Number) string
- func Max(a, b int) int
- func OpenURL(url string) error
- func RemoveDuplicates(xs *[]string)
- func SizeInKB(size int) int
- func StringInSlice(a string, list []string) bool
Constants ¶
View Source
const AccAPIURL string = "https://accapi.appbase.io" // "http://localhost:3000"
AccAPIURL holds the url of Accounts API
View Source
const DevBuild = false
DevBuild is true if the build is for development
Variables ¶
This section is empty.
Functions ¶
func GetKeyForValue ¶
GetKeyForValue returns key for the given value
func JSONNumberToString ¶
JSONNumberToString converts a json.Number to string, properly i.e. no decimal points for a integer json.Number is required instead of normal types in map[..].. based decoding
func OpenURL ¶
OpenURL opens the specified URL in the default browser of the user. https://stackoverflow.com/a/39324149/2295672
func RemoveDuplicates ¶
func RemoveDuplicates(xs *[]string)
RemoveDuplicates removes duplicate values in a slice https://groups.google.com/forum/#!topic/golang-nuts/-pqkICuokio
func StringInSlice ¶
StringInSlice checks if string is in list or not
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.