home
This commit is contained in:
parent
a71a3b5593
commit
cb52890889
16657 changed files with 1483086 additions and 1 deletions
32
home/ags/node_modules/eslint-plugin-es-x/lib/rules/no-async-iteration.js
generated
vendored
Normal file
32
home/ags/node_modules/eslint-plugin-es-x/lib/rules/no-async-iteration.js
generated
vendored
Normal file
|
|
@ -0,0 +1,32 @@
|
|||
/**
|
||||
* @author Toru Nagashima <https://github.com/mysticatea>
|
||||
* See LICENSE file in root directory for full license.
|
||||
*/
|
||||
"use strict"
|
||||
|
||||
module.exports = {
|
||||
meta: {
|
||||
docs: {
|
||||
description: "disallow async iteration.",
|
||||
category: "ES2018",
|
||||
recommended: false,
|
||||
url: "http://eslint-community.github.io/eslint-plugin-es-x/rules/no-async-iteration.html",
|
||||
},
|
||||
fixable: null,
|
||||
messages: {
|
||||
forbidden: "ES2018 async iteration is forbidden.",
|
||||
},
|
||||
schema: [],
|
||||
type: "problem",
|
||||
},
|
||||
create(context) {
|
||||
return {
|
||||
":function[async=true][generator=true]"(node) {
|
||||
context.report({ node, messageId: "forbidden" })
|
||||
},
|
||||
"ForOfStatement[await=true]"(node) {
|
||||
context.report({ node, messageId: "forbidden" })
|
||||
},
|
||||
}
|
||||
},
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue