mirror of
https://github.com/QuiteAFancyEmerald/Holy-Unblocker.git
synced 2025-05-13 03:50:02 -04:00
Updated a few more things
This commit is contained in:
parent
c827e9f7e1
commit
73cdcb3186
47 changed files with 35805 additions and 1102 deletions
18
lib/js/func-args.js
Normal file
18
lib/js/func-args.js
Normal file
|
@ -0,0 +1,18 @@
|
|||
const { Syntax } = require('./esotope');
|
||||
const { createCallExpression, createIdentifier, createArrayExpression } = require('./node-builder');
|
||||
|
||||
function create(type) {
|
||||
return {
|
||||
type,
|
||||
condition: node => {
|
||||
for (let param of node.params) {
|
||||
if (param.type == Syntax.AssignmentPattern) param = param.left;
|
||||
if (param.type == Syntax.ObjectPattern || param.type == Syntax.ArrayPattern) return true;
|
||||
};
|
||||
return false;
|
||||
},
|
||||
run: node => {
|
||||
let num = 0;
|
||||
}
|
||||
};
|
||||
};
|
Loading…
Add table
Add a link
Reference in a new issue