3 ms·
What's the point of a singleton when you can just have variables in an anonymous struct at root level, and functions defined at root as well? var server stru
by vortico 11y ago
What's the point of a singleton when you can just have variables in an anonymous struct at root level, and functions defined at root as well?
var server struct {
host string
port string
}
func serverStart() {
server.host = "..."
server.port = "..."
}