Skip to content

Commit

Permalink
Merge pull request #27840 from studentofcoding/Add-rules-Handle-No-Mu…
Browse files Browse the repository at this point in the history
…ltiple-Onyx-in-file

[No QA] Include newest version of eslint-config-expensify with new rule of no-multiple-onyx-in-file
  • Loading branch information
cristipaval authored Sep 21, 2023
2 parents b225b53 + 977e79d commit ee023d8
Show file tree
Hide file tree
Showing 6 changed files with 14 additions and 8 deletions.
14 changes: 7 additions & 7 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -232,7 +232,7 @@
"electron-builder": "24.6.4",
"eslint": "^7.6.0",
"eslint-config-airbnb-typescript": "^17.1.0",
"eslint-config-expensify": "^2.0.38",
"eslint-config-expensify": "^2.0.39",
"eslint-config-prettier": "^8.8.0",
"eslint-plugin-jest": "^24.1.0",
"eslint-plugin-jsdoc": "^46.2.6",
Expand Down
2 changes: 2 additions & 0 deletions src/components/LHNOptionsList/OptionRowLHNData.js
Original file line number Diff line number Diff line change
Expand Up @@ -195,6 +195,7 @@ export default React.memo(
key: ONYXKEYS.NVP_PREFERRED_LOCALE,
},
}),
// eslint-disable-next-line rulesdir/no-multiple-onyx-in-file
withOnyx({
parentReportActions: {
key: ({fullReport}) => `${ONYXKEYS.COLLECTION.REPORT_ACTIONS}${fullReport.parentReportID}`,
Expand All @@ -209,6 +210,7 @@ export default React.memo(
// However, performance overhead of this is minimized by using memos inside the component.
receiptTransactions: {key: ONYXKEYS.COLLECTION.TRANSACTION},
}),
// eslint-disable-next-line rulesdir/no-multiple-onyx-in-file
withOnyx({
transaction: {
key: ({fullReport, parentReportActions}) =>
Expand Down
1 change: 1 addition & 0 deletions src/pages/EditRequestPage.js
Original file line number Diff line number Diff line change
Expand Up @@ -218,6 +218,7 @@ export default compose(
key: ({route}) => `${ONYXKEYS.COLLECTION.REPORT}${route.params.threadReportID}`,
},
}),
// eslint-disable-next-line rulesdir/no-multiple-onyx-in-file
withOnyx({
parentReport: {
key: ({report}) => `${ONYXKEYS.COLLECTION.REPORT}${report ? report.parentReportID : '0'}`,
Expand Down
1 change: 1 addition & 0 deletions src/pages/iou/MoneyRequestTagPage.js
Original file line number Diff line number Diff line change
Expand Up @@ -109,6 +109,7 @@ export default compose(
key: ONYXKEYS.IOU,
},
}),
// eslint-disable-next-line rulesdir/no-multiple-onyx-in-file
withOnyx({
policyTags: {
key: ({report}) => `${ONYXKEYS.COLLECTION.POLICY_TAGS}${report ? report.policyID : '0'}`,
Expand Down
2 changes: 2 additions & 0 deletions src/pages/iou/steps/MoneyRequestConfirmPage.js
Original file line number Diff line number Diff line change
Expand Up @@ -353,6 +353,7 @@ export default compose(
key: ONYXKEYS.IOU,
},
}),
// eslint-disable-next-line rulesdir/no-multiple-onyx-in-file
withOnyx({
report: {
key: ({route, iou}) => {
Expand All @@ -372,6 +373,7 @@ export default compose(
key: `${ONYXKEYS.COLLECTION.SELECTED_TAB}${CONST.TAB.RECEIPT_TAB_ID}`,
},
}),
// eslint-disable-next-line rulesdir/no-multiple-onyx-in-file
withOnyx({
policy: {
key: ({report}) => `${ONYXKEYS.COLLECTION.POLICY}${report.policyID}`,
Expand Down

0 comments on commit ee023d8

Please sign in to comment.