When I press Ctrl + Alt + L, IDEA removes unused import. I want to turn this feature off, leave the unused imports there. Where can I affect this setting?
First check:
File | Settings | Editor | Formatting | Show "Reformat Code" dialog
Then when you hit Ctrl + Alt + L pop-up dialog will appear.
Uncheck Optimize imports and check Do not show this dialog in the future. Hit Enter or click Run. That's it!
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