How to add DI to Intellij plugin

I was experimenting with Dependency Injection for an IntelliJ plugin and my first thought was, “A plugin is just a JVM program, can’t we use Dagger or Koin?” So, I started experimenting with Koin, as it seemed easier for such projects. I added Koin to the dependencies as I do for any Gradle project, and it worked fine. However, I soon saw the challenges of this approach. Like any DI, you need a starting point to initiate the framework, and for Koin, this means calling:

Read More

Intellij plugin custom LineMarkerProvider

While experimenting with IntelliJ-based IDEs, especially Android Studio, I embarked on creating a feature to add an icon next to the declaration of compose functions with a specific action. The idea was to visually enhance the coding environment for better recognition and interaction with composable functions. Starting Point: Creating a LineMarkerProvider The initial step was to implement a LineMarkerProvider, essential for marking specific lines or elements in the editor with an icon.

Read More