📣 Great news folks!
IntelliJ IDEA 2024.1 EAP-1 has been released with
Alpha version of K2 Kotlin Mode (a.k.a. K2 IDE plugin).
With its new K2 mode, IntelliJ IDEA can now use the embedded K2 Kotlin compiler for analyzing Kotlin code. The K2 Kotlin compiler is being rewritten from the ground up, so we migrated the Kotlin code support in IntelliJ IDEA as well. The performance and stability of the code highlighting and code completion have been significantly improved, but not all IDE features are supported yet.
The following features are already available in this mode:
• Basic IDE functionality like code navigation, code highlighting, code completion, and
Find Usages, as well as the debugger, formatter, and import optimizer.
• Refactorings like
Rename,
Introduce Variable,
Change Signature, and
Safe Delete.
• Some of the most popular inspections and intentions.
Currently, the K2 mode does not support Android, Kotlin Multiplatform Projects, and build.gradle.kts files analysis.
Third-party IntelliJ IDEA plugins depending on the Kotlin plugin need to be adapted to support the new mode. We are going to provide migration guidance for the plugin authors soon. Until that time, the incompatible plugins will be disabled in the K2 mode.
So if you use IntelliJ IDEA, try the new K2 Kotlin mode by checking
Enable K2 Kotlin Mode in
Settings | Languages & Frameworks | Kotlin. You will need to restart the IDE for the change to take effect.
We are actively collecting feedback about this mode. Please share your thoughts or questions right here in the channel, in our
YouTrack, or just wright me in direct messages!