DEV Community

Using IntelliJ IDEA Live Templates

Darshit Patel on September 01, 2019

IntelliJ IDEA is an awesome IDE, and a lesser known and used feature is Live Templates. Live Templates enable you to use code snippets with just a...
Collapse
 
rossholloway94 profile image
Ross Holloway

Another useful one- you can use the $SELECTION$ argument in a live template, so that when you have some code highlighted, you can press ctrl alt T and wrap the selection in your template code.

For example:

Objects.requireNonNull($SELECTION$)