用目录结构表示go包依赖关系

用目录结构表示go包依赖关系

(金庆的专栏 2018.6)

摘自:
https://www.ardanlabs.com/blog/2017/02/package-oriented-design.html

If a package wants to import another package at the same level:

  • Question the current design choices of these packages.
  • If reasonable, move the package inside the source tree for the package that wants to import it.
  • Use the source tree to show the dependency relationships.
相关文章
相关标签/搜索