# How to Import dependency from one file to another inside of a package?

**URL:** <https://discourse.julialang.org/t/how-to-import-dependency-from-one-file-to-another-inside-of-a-package/42891>\
**Category:** New to Julia\
**Tags:** package, modules, code-organization\
**Created:** [July 11, 2020, 10:28am UTC](https://discourse.julialang.org/t/how-to-import-dependency-from-one-file-to-another-inside-of-a-package/42891 "2020-07-11T10:28:31Z")\
**Posts on this page:** 1\
**Showing post:** 7

<div class="post-metadata">

**Author:** ![evanfields](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/evanfields/32/1744_2.png) [@evanfields](https://discourse.julialang.org/u/evanfields)\
**Post date:** [July 23, 2020, 2:34pm UTC](https://discourse.julialang.org/t/how-to-import-dependency-from-one-file-to-another-inside-of-a-package/42891/7 "2020-07-23T14:34:54Z")

</div>

> [@sylvaticus](#):
>
> you can have one top module and several submodules if you wish, although this is in general discouraged

Can you say more about why submodules are discouraged? It seems like your example uses them?

I’ve heard advice like this before but also have seen it [authoritatively contradicted](https://discourse.julialang.org/t/submodules-discouraged/38190/2).

---

_[View the full topic](https://discourse.julialang.org/t/how-to-import-dependency-from-one-file-to-another-inside-of-a-package/42891)._
