Go newbie: how to organize code
Hello, I'm new to Go, and i have some doubts about how to organize code. I don't know if I understand packages correctly. Let's asume that I'm making a rest api, and I wanna organize my code by functionality. Will be this organization correct?
users.go will contain all user code: types, handler functions… And in main.go I will import this package as "[fullpath]/users"
Is this correct? If not, what will be the correct way of doing this?
Thanks in advance.
Submitted August 11, 2017 at 05:35PM by dp404e
via reddit http://ift.tt/2fxS7TR