try using go generate

Original link:https://liqiang.io/post/using-go-generate-with-go-a10df252

In Go, there is an unwritten habit, that is, many people like to generate code, such as the directory structure of the project, the stub code of grpc are all generated by tools, and the small ones such as static files are embedded in the code and automatically generated The String form of the enum type, etc., the schema of the generated code is always visible anyway.

This article is reprinted from:https://liqiang.io/post/using-go-generate-with-go-a10df252
This site is for inclusion only, and the copyright belongs to the original author.

Leave a Comment