Skip to content

Commit b78967e

Browse files
committed
Merge branch 'main' of github.com:Expensify/App into fix/composer-not-being-cleared
2 parents cf0ad39 + 7557e45 commit b78967e

File tree

192 files changed

+2308
-1286
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

192 files changed

+2308
-1286
lines changed

.eslintrc.js

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -95,7 +95,8 @@ module.exports = {
9595
'plugin:you-dont-need-lodash-underscore/all',
9696
'prettier',
9797
],
98-
plugins: ['@typescript-eslint', 'jsdoc', 'you-dont-need-lodash-underscore', 'react-native-a11y', 'react', 'testing-library'],
98+
plugins: ['@typescript-eslint', 'jsdoc', 'you-dont-need-lodash-underscore', 'react-native-a11y', 'react', 'testing-library', 'eslint-plugin-react-compiler'],
99+
ignorePatterns: ['lib/**'],
99100
parser: '@typescript-eslint/parser',
100101
parserOptions: {
101102
project: path.resolve(__dirname, './tsconfig.json'),
@@ -108,7 +109,6 @@ module.exports = {
108109
},
109110
rules: {
110111
// TypeScript specific rules
111-
'@typescript-eslint/no-unsafe-member-access': 'off',
112112
'@typescript-eslint/no-unsafe-assignment': 'off',
113113
'@typescript-eslint/prefer-enum-initializers': 'error',
114114
'@typescript-eslint/no-var-requires': 'off',
@@ -188,6 +188,7 @@ module.exports = {
188188
touchables: ['PressableWithoutFeedback', 'PressableWithFeedback'],
189189
},
190190
],
191+
'react-compiler/react-compiler': 'error',
191192

192193
// Disallow usage of certain functions and imports
193194
'no-restricted-syntax': [

.github/actions/javascript/authorChecklist/categories/newComponentCategory.ts

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
import * as github from '@actions/github';
2+
import type {WebhookPayload} from '@actions/github/lib/interfaces';
23
import {parse} from '@babel/parser';
34
import traverse from '@babel/traverse';
45
import CONST from '@github/libs/CONST';
@@ -8,6 +9,15 @@ import type Category from './Category';
89

910
type SuperClassType = {superClass: {name?: string; object: {name: string}; property: {name: string}} | null; name: string};
1011

12+
type GithubPaylod = WebhookPayload & {
13+
// eslint-disable-next-line @typescript-eslint/naming-convention
14+
pull_request?: {
15+
head: {
16+
ref?: string;
17+
};
18+
};
19+
};
20+
1121
const items = [
1222
"I verified that similar component doesn't exist in the codebase",
1323
'I verified that all props are defined accurately and each prop has a `/** comment above it */`',
@@ -77,7 +87,7 @@ async function detectReactComponentInFile(filename: string): Promise<boolean | u
7787
owner: CONST.GITHUB_OWNER,
7888
repo: CONST.APP_REPO,
7989
path: filename,
80-
ref: github.context.payload.pull_request?.head.ref,
90+
ref: (github.context.payload as GithubPaylod)?.pull_request?.head.ref,
8191
};
8292
try {
8393
const {data} = await GithubUtils.octokit.repos.getContent(params);

0 commit comments

Comments
 (0)