The reason for === is for the inherent type-checking. If I'm understanding Javascript correctly, viewModel.dirty will evaluate to true if, for some reason, viewModel.dirty is set as a string and is not null or empty. The === makes sure both sides of the equality are the same type and the same value.