Skip to content

Instantly share code, notes, and snippets.

@mmichlin66
Last active October 15, 2020 01:59
Show Gist options
  • Save mmichlin66/c0a15c66b57109888e6c0518fc43c307 to your computer and use it in GitHub Desktop.
Save mmichlin66/c0a15c66b57109888e6c0518fc43c307 to your computer and use it in GitHub Desktop.
Virtualizing TypeScript Properties with Proxy and Decorator - listing 5
class Base
{
@virtual a = 1;
b = this.a;
}
class Derived extends Base
{
a = 2;
}
let obj = new Derived();
console.log( obj.b * 10);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment