The Go team has released the new 1.18 version of Go. The new release has a lot of enhancements, such as Generics, the most awaited feature, any which is basically an alias of interface{} and many more.

type any = interface{}

With the any type definition, Go has replaced all references to interface{}. If you want to rewrite all occurrence of interface{} in your project, just use the following command:

gofmt -r 'interface{} -> any' -w *.go

If you found this information useful, subscribe to my articles.