check if field inside object code example Example: check if field exists in object javascript if ('field' in obj) { }