lundi 27 mai 2019

Shorter if statement in Javascript

I'm newbe in Js I wanna check to statuses have same value:

if (data.a_status == 'approved' && data.b_status == 'approved' && data.c_status == 'approved')

Can I write this shorter? I can't find any material how to check same value in three variables

Aucun commentaire:

Enregistrer un commentaire