When you have decorated class, from inside that class should you be able to access decorated or original version of it?
For example.
const decorator = (x) => {
console.log('test');
return x;
};
@decorator
class A {
foo() {
return new A();
}
}
const a = new A();//this invokes console.log
const b = a.foo();// maybe this should too?