Update checked-in dependencies
This commit is contained in:
parent
7269bf610b
commit
e5a7c904c1
215 changed files with 41592 additions and 3253 deletions
18
node_modules/eslint-plugin-github/lib/rules/async-currenttarget.js
generated
vendored
18
node_modules/eslint-plugin-github/lib/rules/async-currenttarget.js
generated
vendored
|
|
@ -10,16 +10,24 @@ module.exports = {
|
|||
|
||||
create(context) {
|
||||
const scopeDidWait = new WeakSet()
|
||||
const sourceCode = context.sourceCode ?? context.getSourceCode()
|
||||
|
||||
return {
|
||||
AwaitExpression() {
|
||||
scopeDidWait.add(context.getScope(), true)
|
||||
AwaitExpression(node) {
|
||||
scopeDidWait.add(sourceCode.getScope ? sourceCode.getScope(node) : context.getScope())
|
||||
},
|
||||
MemberExpression(node) {
|
||||
if (node.property && node.property.name === 'currentTarget') {
|
||||
const scope = context.getScope()
|
||||
if (scope.block.async && scopeDidWait.has(scope)) {
|
||||
context.report({node, message: 'event.currentTarget inside an async function is error prone'})
|
||||
let scope = sourceCode.getScope ? sourceCode.getScope(node) : context.getScope()
|
||||
while (scope) {
|
||||
if (scopeDidWait.has(scope)) {
|
||||
context.report({
|
||||
node,
|
||||
message: 'event.currentTarget inside an async function is error prone',
|
||||
})
|
||||
break
|
||||
}
|
||||
scope = scope.upper
|
||||
}
|
||||
}
|
||||
},
|
||||
|
|
|
|||
18
node_modules/eslint-plugin-github/lib/rules/async-preventdefault.js
generated
vendored
18
node_modules/eslint-plugin-github/lib/rules/async-preventdefault.js
generated
vendored
|
|
@ -10,16 +10,24 @@ module.exports = {
|
|||
|
||||
create(context) {
|
||||
const scopeDidWait = new WeakSet()
|
||||
const sourceCode = context.sourceCode ?? context.getSourceCode()
|
||||
|
||||
return {
|
||||
AwaitExpression() {
|
||||
scopeDidWait.add(context.getScope(), true)
|
||||
AwaitExpression(node) {
|
||||
scopeDidWait.add(sourceCode.getScope ? sourceCode.getScope(node) : context.getScope())
|
||||
},
|
||||
CallExpression(node) {
|
||||
if (node.callee.property && node.callee.property.name === 'preventDefault') {
|
||||
const scope = context.getScope()
|
||||
if (scope.block.async && scopeDidWait.has(scope)) {
|
||||
context.report({node, message: 'event.preventDefault() inside an async function is error prone'})
|
||||
let scope = sourceCode.getScope ? sourceCode.getScope(node) : context.getScope()
|
||||
while (scope) {
|
||||
if (scopeDidWait.has(scope)) {
|
||||
context.report({
|
||||
node,
|
||||
message: 'event.preventDefault() inside an async function is error prone',
|
||||
})
|
||||
break
|
||||
}
|
||||
scope = scope.upper
|
||||
}
|
||||
}
|
||||
},
|
||||
|
|
|
|||
2
node_modules/eslint-plugin-github/lib/rules/filenames-match-regex.js
generated
vendored
2
node_modules/eslint-plugin-github/lib/rules/filenames-match-regex.js
generated
vendored
|
|
@ -32,7 +32,7 @@ module.exports = {
|
|||
|
||||
return {
|
||||
Program(node) {
|
||||
const filename = context.getFilename()
|
||||
const filename = context.filename ?? context.getFilename()
|
||||
const absoluteFilename = path.resolve(filename)
|
||||
const parsed = parseFilename(absoluteFilename)
|
||||
const shouldIgnore = isIgnoredFilename(filename)
|
||||
|
|
|
|||
2
node_modules/eslint-plugin-github/lib/rules/no-useless-passive.js
generated
vendored
2
node_modules/eslint-plugin-github/lib/rules/no-useless-passive.js
generated
vendored
|
|
@ -32,7 +32,7 @@ module.exports = {
|
|||
if (i === -1) return
|
||||
const passiveProp = options.properties[i]
|
||||
const l = options.properties.length
|
||||
const source = context.getSourceCode()
|
||||
const source = context.sourceCode ?? context.getSourceCode()
|
||||
context.report({
|
||||
node: passiveProp,
|
||||
message: `"${name.value}" event listener is not cancellable and so \`passive: true\` does nothing.`,
|
||||
|
|
|
|||
6
node_modules/eslint-plugin-github/package.json
generated
vendored
6
node_modules/eslint-plugin-github/package.json
generated
vendored
|
|
@ -1,6 +1,6 @@
|
|||
{
|
||||
"name": "eslint-plugin-github",
|
||||
"version": "5.1.4",
|
||||
"version": "5.1.5",
|
||||
"description": "An opinionated collection of ESLint shared configs and rules used by GitHub.",
|
||||
"main": "lib/index.js",
|
||||
"entries": [
|
||||
|
|
@ -67,9 +67,9 @@
|
|||
"@github/prettier-config": "0.0.6",
|
||||
"chai": "^5.0.0",
|
||||
"eslint": "^9.14.0",
|
||||
"eslint-doc-generator": "^1.4.3",
|
||||
"eslint-doc-generator": "^2.0.1",
|
||||
"eslint-plugin-eslint-plugin": "^6.1.0",
|
||||
"mocha": "^10.0.0",
|
||||
"mocha": "^11.0.1",
|
||||
"npm-run-all": "^4.1.5"
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue