Is there an easy way to make all string compares in a js file case-insensitive? Here's a simple example of a normal check:
var message = 'This is a Test';
var isTest = message.toLowerCase().indexOf('test') > -1;
This isn't a bad approach for a single check but it gets verbose if it needs to be done 10+ times in a file. Is there an easier way to make string compares case-insensitive for the entire scope of a js file?