Skip to content

Commit

Permalink
avoid lint error
Browse files Browse the repository at this point in the history
  • Loading branch information
SimenB committed Dec 10, 2024
1 parent d1bcc1c commit cc71fe4
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 1 deletion.
2 changes: 1 addition & 1 deletion packages/babel-plugin-jest-hoist/src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -371,7 +371,7 @@ export default function jestHoist(): PluginObj<{
if (hoistedJestGetters.has(callExpr.node)) {
const mockStmt = callExpr.getStatementParent();

if (mockStmt?.parentPath.isBlock()) {
if (mockStmt && mockStmt.parentPath.isBlock()) {
stack.at(-1)!.calls.push(mockStmt.node);
mockStmt.remove();
}
Expand Down
6 changes: 6 additions & 0 deletions scripts/lintTs.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -111,6 +111,12 @@ try {
'@typescript-eslint/no-redundant-type-constituents': 'off',
},
},
// {
// files: ['packages/babel-plugin-jest-hoist/src/index.ts'],
// rules: {
// '@typescript-eslint/strict-boolean-expressions': 'off',
// },
// },
],
parser: '@typescript-eslint/parser',
parserOptions: {
Expand Down

0 comments on commit cc71fe4

Please sign in to comment.