Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- class Test {
- constructor(num) {
- this.num = num;
- }
- foo = () => {
- return () => {
- console.log(this);
- console.log(this.num);
- }
- }
- }
- test = new Test(100);
- f = test.foo();
- f();
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement