How do I get the slices before and after a separator from a string? In Python, I can simply write
user, _, domain = "foo@example.com".partition("@")
assert user == "foo"
assert domain == "example.com"
Notably, this also works if multiple occurrences of the separator are present in the input, or none at all. How can I split a string that easily in Go?