Skip to content

Commit

Permalink
Merge pull request #44112 from Expensify/Rory-UpgradeESLint
Browse files Browse the repository at this point in the history
[No QA] Upgrade ESLint
  • Loading branch information
srikarparsi authored Jun 21, 2024
2 parents 88f96c3 + 6be5096 commit 5158966
Show file tree
Hide file tree
Showing 22 changed files with 745 additions and 1,152 deletions.
1 change: 1 addition & 0 deletions .eslintignore
Original file line number Diff line number Diff line change
Expand Up @@ -9,3 +9,4 @@ android/**/build/**
docs/vendor/**
docs/assets/**
web/gtm.js
**/.expo/**
6 changes: 4 additions & 2 deletions .eslintrc.js
Original file line number Diff line number Diff line change
Expand Up @@ -107,10 +107,9 @@ module.exports = {
__DEV__: 'readonly',
},
rules: {
// TypeScript specific rules
'@typescript-eslint/no-unsafe-member-access': 'off',
'@typescript-eslint/no-unsafe-assignment': 'off',

// TypeScript specific rules
'@typescript-eslint/prefer-enum-initializers': 'error',
'@typescript-eslint/no-var-requires': 'off',
'@typescript-eslint/no-non-null-assertion': 'error',
Expand Down Expand Up @@ -217,6 +216,8 @@ module.exports = {
// Other rules
curly: 'error',
'you-dont-need-lodash-underscore/throttle': 'off',
// The suggested alternative (structuredClone) is not supported in Hermes:https://github.com/facebook/hermes/issues/684
'you-dont-need-lodash-underscore/clone-deep': 'off',
'prefer-regex-literals': 'off',
'valid-jsdoc': 'off',
'jsdoc/no-types': 'error',
Expand Down Expand Up @@ -259,6 +260,7 @@ module.exports = {
// Remove once no JS files are left
{
files: ['*.js', '*.jsx'],
extends: ['plugin:@typescript-eslint/disable-type-checked'],
rules: {
'@typescript-eslint/prefer-nullish-coalescing': 'off',
'@typescript-eslint/no-unsafe-return': 'off',
Expand Down
2 changes: 1 addition & 1 deletion .github/libs/versionUpdater.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ const SEMANTIC_VERSION_LEVELS = {
} as const;
type SemverLevel = ValueOf<typeof SEMANTIC_VERSION_LEVELS>;

const MAX_INCREMENTS = 99 as const;
const MAX_INCREMENTS = 99;

function isValidSemverLevel(str: string): str is SemverLevel {
return Object.keys(SEMANTIC_VERSION_LEVELS).includes(str);
Expand Down
Loading

0 comments on commit 5158966

Please sign in to comment.