# Imports

**URL:** <https://discuss.kotlinlang.org/t/imports/1571>\
**Category:** Language Design\
**Created:** [March 31, 2016, 1:03pm UTC](https://discuss.kotlinlang.org/t/imports/1571 "2016-03-31T13:03:44Z")\
**Posts on this page:** 1\
**Showing post:** 1

<div class="post-metadata">

**Author:** ![norswap](https://sea1.discourse-cdn.com/flex019/user_avatar/discuss.kotlinlang.org/norswap/32/1737_2.png) [@norswap](https://discuss.kotlinlang.org/u/norswap)\
**Post date:** [March 31, 2016, 1:03pm UTC](https://discuss.kotlinlang.org/t/imports/1571/1 "2016-03-31T13:03:44Z")

</div>

Here are two suggestions for imports.

**1) It would be really cool to be have named package imports:**

```
import com.pkg.whatever as whatev
...
val x = whatev.somePackageLevelFunction()

```

You can already do that with objects, but sometimes you don’t want to group your function within objects and have to use `import com.pkg.whatever.WrapperObject.*` a lot internally. Especially since auto-completion does not kick in.

**2) Extension methods could use some import-level support.**

It’s not rare that I want to import all extensions to a type X from a certain package. But I can’t do that, you either import everything (`import com.pkg.*`) or you must import your extension methods one by one.

You could put all extensions methods in a separate package (and it’s really nice that you don’t need to put them in a separate folder!), but again, internally you’ll need to use `import com.pkg.xextensions.*` a lot).

It could look something like this:

```
import com.pkg.(X) // import all extension methods for X defined in `com.pkg`

```

---

_[View the full topic](https://discuss.kotlinlang.org/t/imports/1571)._
