Skip to content

Commit

Permalink
eslint: detect unreachable code
Browse files Browse the repository at this point in the history
  • Loading branch information
kesha-antonov committed Aug 20, 2024
1 parent 6921592 commit 9d457f1
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 2 deletions.
1 change: 1 addition & 0 deletions .eslintrc.cjs
Original file line number Diff line number Diff line change
Expand Up @@ -111,6 +111,7 @@ module.exports = {
'brace-style': ['error', '1tbs', { allowSingleLine: false }],
'nonblock-statement-body-position': ['error', 'below'],
'@stylistic/jsx-closing-bracket-location': ['error', 'line-aligned'],
'no-unreachable': 'error',
},
globals: {
describe: 'readonly',
Expand Down
2 changes: 0 additions & 2 deletions src/Day.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -57,8 +57,6 @@ export function Day<TMessage extends IMessage = IMessage> ({
if (currentMessage == null || isSameDay(currentMessage, previousMessage))
return null

return null

return (
<View style={[styles.container, containerStyle]}>
<View style={wrapperStyle}>
Expand Down
2 changes: 2 additions & 0 deletions tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,8 @@
"experimentalDecorators": true,
"preserveConstEnums": true,
"sourceMap": true,
"allowJs": true,
"checkJs": true,
"strictNullChecks": true,
"skipDefaultLibCheck": true,
"skipLibCheck": true,
Expand Down

0 comments on commit 9d457f1

Please sign in to comment.