Go 1.22
As said by @Mart, There's a library function for that, example usage:
w := [][]string{{"a", "b", "c"}, {"d", "e", "f"}} v := slices.Concat(w...) fmt.Println(v) // [a b c d e f]
see - https://pkg.go.dev/[email protected]#Concat