Skip to content

Commit 53896ae

Browse files
chore(lint): enforce react/capitalized-calls (#25109)
1 parent d19ec7d commit 53896ae

4 files changed

Lines changed: 4 additions & 0 deletions

File tree

‎apps/mobile/src/features/threads/ThreadArrangementSheet.tsx‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -105,6 +105,7 @@ function DragHandle(props: {
105105
latest.current = props;
106106
const gesture = useMemo(
107107
() =>
108+
// oxlint-disable-next-line react/capitalized-calls -- Gesture.Pan is a gesture factory, not a React component.
108109
Gesture.Pan()
109110
.enabled(!props.disabled)
110111
.minDistance(0)

‎apps/mobile/src/features/threads/ThreadQueueControl.tsx‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -614,6 +614,7 @@ function QueueDragHandle(props: {
614614
const onStart = useEffectEvent(() => props.onStart());
615615
const onMove = useEffectEvent((y: number) => props.onMove(y));
616616
const onEnd = useEffectEvent((y: number, success: boolean) => props.onEnd(y, success));
617+
// oxlint-disable-next-line react/capitalized-calls -- Gesture.Pan is a gesture factory, not a React component.
617618
const gesture = Gesture.Pan()
618619
.enabled(!props.disabled)
619620
.minDistance(0)

‎apps/mobile/src/lib/useHoverGesture.ts‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ export function useHoverGesture(disabled = false) {
55
const [hovered, setHovered] = useState(false);
66
const hoverGesture = useMemo(
77
() =>
8+
// oxlint-disable-next-line react/capitalized-calls -- Gesture.Hover is a gesture factory, not a React component.
89
Gesture.Hover()
910
.manualActivation(true)
1011
.enabled(!disabled)

‎vite.config.ts‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -216,6 +216,7 @@ export default defineConfig({
216216
perf: "warn",
217217
},
218218
rules: {
219+
"react/capitalized-calls": "error",
219220
"typescript/no-extraneous-class": "error",
220221
"eslint/no-empty-pattern": "error",
221222
"eslint/no-new": "error",

0 commit comments

Comments
 (0)