Only allow Identifiers, Patterns and Rest in parameters of FunctionDeclarations
This commit is contained in:
parent
d86b831364
commit
0f685d9b42
@ -288,7 +288,14 @@ export const functionCommon = {
|
|||||||
params: {
|
params: {
|
||||||
validate: chain(
|
validate: chain(
|
||||||
assertValueType("array"),
|
assertValueType("array"),
|
||||||
assertEach(assertNodeType("LVal")),
|
assertEach(
|
||||||
|
assertNodeType(
|
||||||
|
"Identifier",
|
||||||
|
"Pattern",
|
||||||
|
"RestElement",
|
||||||
|
"TSParameterProperty",
|
||||||
|
),
|
||||||
|
),
|
||||||
),
|
),
|
||||||
},
|
},
|
||||||
generator: {
|
generator: {
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user