Skip to content Skip to sidebar Skip to footer

ESLint Error No-unneeded-ternary

ESLint is telling me this error message inside my JS module: error no-unneeded-ternary Unnecessary use of conditional expression for default assignment The error comes in the get

Solution 1:

You don't need a ternary when a simple val || defaultVal will do.


Solution 2:


Post a Comment for "ESLint Error No-unneeded-ternary"