I need to compare two objects. But it fails.
Code:
export class SourceValues {
  ...
  static INDICATOR: ISourceValue = { text: 'Indicator', value: 'Indicator' };
  ...
}
somewhere else
let a = { text: 'Indicator', value: 'Indicator' } as ISourceValue;
...
if(a === SourceValues.INDICATOR){ // I don't want any change here
//do something
}
When I run this, both a and SourceValues.INDICATOR holds the same value / object. but the comparison fails. Let me know your thoughts. Thanks.
 
     
    