Kotlin Plugin Released With IntelliJ IDEA 2020.3
We’ve changed the release cycle of the Kotlin plugin, so that all major updates are now synced with IntelliJ IDEA releases.
In this release:
- Inline refactoring is now cross-language: you can apply it to any Kotlin elements defined in Java and the conversion will be performed automatically.
- Now you can search and replace parts of your code based on its structure.
- Building performant and beautiful user interfaces is now easy with the new experimental Jetpack Compose templates.
New infrastructure and release cycle
We now ship new versions of the Kotlin plugin with every release of the IntelliJ Platform. IDE support for the latest version of the language will be available for the latest two versions of IntelliJ IDEA and for the latest version of Android Studio.
We’ve made this change to minimize the time it takes us to apply platform changes, and to make sure that the IntelliJ team gets the latest Kotlin IDE fixes quickly and with enough time to test them.
The Kotlin plugin now supports cross-language conversion. Starting with version 2020.3 of the Kotlin plugin, you can use inline refactoring actions for Kotlin elements defined in Java.
You can apply them via Refactor / Inline… or ⌥⌘N on Mac or Ctrl+Alt+N on Windows and Linux.
We’ve improved the inlining of lambda expressions. You no longer have to rewrite your code after you inline it; the IDE now analyzes the lambda syntax more thoroughly and formats the lambdas correctly.
Structural Search and Replace for Kotlin
Structural search and replace (SSR) actions are now available for Kotlin. Now you can find and replace code patterns, whilst taking the syntax and semantics of the source code into account.
To use the feature, go to Edit | Find | Search Structurally…. You can also write a search template or choose
Existing Templates… by clicking the tools icon in the top right corner of the window.
You can add filters for variables to narrow down your search, for example, the
Full support of EditorConfig
Starting from 2020.3, the Kotlin plugin fully supports storing code formatting settings in the .editorconfig.
Desktop and Multiplatform templates for Jetpack Compose for Desktop
Jetpack compose is a modern UI framework for Kotlin that makes it easy and enjoyable to build performant and beautiful user interfaces. The new experimental Jetpack Compose for Desktop templates are now available in the Kotlin Project Wizard. You can create a project using Desktop or Multiplatform templates. A desktop template is for the desktop JVM platform, and the Multiplatform template is for the desktop JVM platform and Android with shared code in common modules.
Learn about the Kotlin Plugin updates in What’s new.
We’ve added a lot of new IDE features that are all designed for greater productivity and to make working with the code more fun.
- Now when you run an application in debug mode, you get clickable inline hints that you can expand to see all the fields that belong to the variable. Moreover, you can change the variable values inside the drop-down list.
- Work together on your code with your colleagues. In IntelliJ IDEA 2020.3 you can use Code With Me, a tool for collaborative development and remote pair programming.
- In IntelliJ IDEA 2020.3, we made it easier to start analyzing snapshots from the updated Profiler tool window. The Profiler allows you to view and study snapshots to track down performance and memory issues. You can open a snapshot file in the Recent Snapshots area and analyze it from there.
- Evaluate math expressions and find Git branches and commits by their hashes in Search Everywhere.
- Split the editor with drag and drop tabs.
These and other updates are described in detail in What’s new for IDEA 2020.3
Don’t forget to share your feedback!
You can do that by
- Adding comments to this blog post.
- Reporting an issue to our issue tracker.