I'm trying to add Lombok to my Spring Boot project in IntelliJ IDEA. So far, I've
added the plugin under Settings - Plugins (version 0.13.16)
added compile('org.projectlombok:lombok')
to my Gradle dependencies
enabled annotation processing
It still doesn't recognize either the Lombok import or the annotations.
What am I missing?
Solved:
I had to run an update on my Gradle file.
Adding the Lombok Plugin in IDE (Eclipse) Downloaded jar from https://projectlombok.org/download or use the jar which is downloaded from your maven build. Execute command in terminal: java -jar lombok. jar. This command will open window as show in the picture below, install and quit the installer and restart eclipse.
Go to File > Settings > Plugins. Click on Browse repositories... Search for Lombok Plugin. Click on Install plugin.
1. Introduction to lombok. Lombok is used to reduce boilerplate code for model/data objects, e.g., it can generate getters and setters for those object automatically by using Lombok annotations. The easiest way is to use the @Data annotation.
You need to Enable Annotation Processing on IntelliJ IDEA
> Settings > Build, Execution, Deployment > Compiler > Annotation Processors
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With