diff --git a/package.json b/package.json index 5a5c1930c..fdabaecdb 100644 --- a/package.json +++ b/package.json @@ -113,7 +113,7 @@ "eslint-plugin-jest": "24.1.3", "eslint-plugin-prettier-internal-rules": "link:scripts/tools/eslint-plugin-prettier-internal-rules", "eslint-plugin-react": "7.22.0", - "eslint-plugin-unicorn": "27.0.0", + "eslint-plugin-unicorn": "28.0.0", "execa": "5.0.0", "jest": "26.6.3", "jest-snapshot-serializer-ansi": "1.0.0", diff --git a/src/language-handlebars/utils.js b/src/language-handlebars/utils.js index 7b41711cb..963f561ca 100644 --- a/src/language-handlebars/utils.js +++ b/src/language-handlebars/utils.js @@ -49,7 +49,7 @@ function isWhitespaceNode(node) { } function isNodeOfSomeType(node, types) { - return node && types.some((type) => node.type === type); + return node && types.includes(node.type); } function isParentOfSomeType(path, types) { diff --git a/yarn.lock b/yarn.lock index 3a729524f..4e5e1edca 100644 --- a/yarn.lock +++ b/yarn.lock @@ -3065,7 +3065,6 @@ eslint-plugin-jest@24.1.3: "eslint-plugin-prettier-internal-rules@link:scripts/tools/eslint-plugin-prettier-internal-rules": version "0.0.0" - uid "" eslint-plugin-react@7.22.0: version "7.22.0" @@ -3084,10 +3083,10 @@ eslint-plugin-react@7.22.0: resolve "^1.18.1" string.prototype.matchall "^4.0.2" -eslint-plugin-unicorn@27.0.0: - version "27.0.0" - resolved "https://registry.yarnpkg.com/eslint-plugin-unicorn/-/eslint-plugin-unicorn-27.0.0.tgz#d12436409e399ab75c826bbb17b202846a276e5a" - integrity sha512-uUvlueTa4SpkvLjbkqx08JbB0tY6XxOAa8vlfwbTzITfVNy3go3QzPCus49fO5M/mfooOuraIDVkaqan/pLAHg== +eslint-plugin-unicorn@28.0.0: + version "28.0.0" + resolved "https://registry.yarnpkg.com/eslint-plugin-unicorn/-/eslint-plugin-unicorn-28.0.0.tgz#41bbc9a62119a9d19466942f9ad059c57d54532f" + integrity sha512-+VTwBbHsJk/jACDxeWhtLfLxru+9cV+jt/mX7a/WjHa/5xrS0S4ZFYJSg4z54s0waeAAO9D+CPB39Pch40qABg== dependencies: ci-info "^2.0.0" clean-regexp "^1.0.0" @@ -5984,16 +5983,11 @@ regex-not@^1.0.0, regex-not@^1.0.2: extend-shallow "^3.0.2" safe-regex "^1.1.0" -regexp-tree@^0.1.22: +regexp-tree@^0.1.22, regexp-tree@~0.1.1: version "0.1.23" resolved "https://registry.yarnpkg.com/regexp-tree/-/regexp-tree-0.1.23.tgz#8a8ce1cc5e971acef62213a7ecdb1f6e18a1f1b2" integrity sha512-+7HWfb4Bvu8Rs2eQTUIpX9I/PlQkYOuTNbRpKLJlQpSgwSkzFYh+pUj0gtvglnOZLKB6YgnIgRuJ2/IlpL48qw== -regexp-tree@~0.1.1: - version "0.1.21" - resolved "https://registry.yarnpkg.com/regexp-tree/-/regexp-tree-0.1.21.tgz#55e2246b7f7d36f1b461490942fa780299c400d7" - integrity sha512-kUUXjX4AnqnR8KRTCrayAo9PzYMRKmVoGgaz2tBuz0MF3g1ZbGebmtW0yFHfFK9CmBjQKeYIgoL22pFLBJY7sw== - regexp-util@1.2.2, regexp-util@^1.2.0, regexp-util@^1.2.1: version "1.2.2" resolved "https://registry.yarnpkg.com/regexp-util/-/regexp-util-1.2.2.tgz#5cf599134921eb0d776e41d41e9c0da33f0fa2fc"