Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Kotlin's typealias is not handled correctly #2311

Closed
IngoHaumann-TomTom opened this issue Jan 14, 2022 · 4 comments
Closed

Kotlin's typealias is not handled correctly #2311

IngoHaumann-TomTom opened this issue Jan 14, 2022 · 4 comments
Labels

Comments

@IngoHaumann-TomTom
Copy link

Describe the bug
When adding a typealias type to your project, the following happens:

  • It get recognized as a type and links to it get resolved.
  • All these links have targets that do not exist in the Dokka output.
  • The alias itself cannot be found using Dokka's search.

Expected behaviour
A typealias is a Kotlin language feature and should be resolvable.

To Reproduce
Add a public typealias BrokenType = SomeOtherGenericType<argument> to the Dokka input.

Dokka configuration
Irrelevant.

Installation

  • Operating system: Linux
  • Build tool: Gradle v7.2
  • Dokka version: 1.5.31
@IgnatBeresnev
Copy link
Member

IgnatBeresnev commented Jan 14, 2022

Hi! Thanks for the report

Testing it out on 1.6.10, I can see that the typealias definition itself indeed cannot be found using search, although it does find signatures where it is used

I want to clarify what exactly you mean by

All these links have targets that do not exist in the Dokka output.

If I click on BrokenType in the signature, it navigates me to its definition on the module's page. Perhaps that was fixed in 1.6 for the new format? Can you update and see if the problem you're having is gone?

usage page

after clicking, it focuses the definition

@IngoHaumann-TomTom
Copy link
Author

What I mean is that Dokka finds the instances and makes them clickable, but the targets of those links do not exist; like they are not generated.

We have updating to 1.6 on our backlog, as we've noticed it's not just a matter of updating the version number.

@IngoHaumann-TomTom
Copy link
Author

In 1.6.21, this issue still exists. You can come across it while clicking around, and it will end up on the typealias definition, but the high level search still cannot point you directly to that definition; only its usages. Since a typealias is a first-class citizen of Kotlin, it is expected to show up in search results directly.

@vmishenev
Copy link
Member

In Dokka 1.9.0 typealiases will have their own separate pages, so they will be clickable. Also, the search of typealises will be fixed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants