I have an enum like this that I use as a type
export enum PathDirection {
ASCENDING="ASCENDING";
DESCENDING="DESCENDING";
};
In some part of my code, I would like to get the opposite path direction as the one I have. Something like this :
let myVar = PathDirection.ASCENDING;
myVar = !myVar;
Is there any way to overload the logical operator !
to make this happen ?