Use ternary operations when you want your code to be readable.
Using if/else, introduces boilerplate code, which can be hard to the eyes
Also, when you need to return a or b based on a condition.
...