-
Notifications
You must be signed in to change notification settings - Fork 1
/
astexplorer
75 lines (62 loc) · 970 Bytes
/
astexplorer
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
num = 6;
var num;
var num2 = null;
let num1 = 6;
console.log("hello world")
console["log"]("123");
var a = {};
a.x = a = {n: 2};
var a = num1++;
var obj = {attr1:1,attr2:2};
var {arrt1,arrt2} = obj;
const obj3 = {a:1,b:2};
const obj4 = {...obj3,c:3};
delete obj3.a;
delete obj3['b'];
if(true){
const a = 1;
}
a("1")
a.apply(this,["123"])
var fn = (...obj) => {};
var fn = function(a = '1'){
return 1;
}
function Man(){
}
Man.prototype = {
say: function(){
}
};
{}
var f = {
a(){},
c : ()=>{},
b:1
}
try{}catch(err){}
if(a){
}else if(b){}
else{}
var s = (1,2,3);
const arr = [1, 2, 3];
const arr2 = [...arr, 4,5,6]
var arr11 = [1,{},null,undefined,false,...b];
var a = 0;
for(let i = 0; i<5; i++){
if(i == 2) continue;
a++;
}
function Human(){
this.name = 'ximing'
}
Human.prototype.say = function(){}
{human: new Human(), Human};
function Human1(){ return new.target}
class A{
constructor(){
this.a = 1;
}
b(){}
c = ()=>{}
}