Javascript: How to check if a string is empty? [duplicate] December 18, 2022 by Tarik I check length. if (str.length == 0) { }