Skip to content

Commit

Permalink
fix: react compiler lint errors
Browse files Browse the repository at this point in the history
  • Loading branch information
tien committed Feb 16, 2025
1 parent 57c9337 commit b4cb126
Show file tree
Hide file tree
Showing 12 changed files with 23 additions and 0 deletions.
9 changes: 9 additions & 0 deletions .vscode/settings.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,5 +5,14 @@
"mode": "auto"
}
],
"files.readonlyInclude": {
"**/routeTree.gen.ts": true
},
"files.watcherExclude": {
"**/routeTree.gen.ts": true
},
"search.exclude": {
"**/routeTree.gen.ts": true
},
"typescript.tsdk": "node_modules/typescript/lib"
}
2 changes: 2 additions & 0 deletions src/components/param/accountId.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,7 @@ export function AccountIdParam({
onChangeValue(account.address);
}
},
// eslint-disable-next-line react-compiler/react-compiler
// eslint-disable-next-line react-hooks/exhaustive-deps
[account],
);
Expand Down Expand Up @@ -99,6 +100,7 @@ function CustomAccountParam({
() => {
onChangeValue(derivedValue);
},
// eslint-disable-next-line react-compiler/react-compiler
// eslint-disable-next-line react-hooks/exhaustive-deps
[derivedValue],
);
Expand Down
1 change: 1 addition & 0 deletions src/components/param/array.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,7 @@ function INTERNAL_ArrayParam<T>({
() => {
onChangeValue(derivedArray);
},
// eslint-disable-next-line react-compiler/react-compiler
// eslint-disable-next-line react-hooks/exhaustive-deps
[derivedArray],
);
Expand Down
2 changes: 2 additions & 0 deletions src/components/param/binary.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,7 @@ function TextBinaryParam({ onChangeValue, defaultValue }: BinaryParamProps) {
onChangeValue(Binary.fromText(value));
}
},
// eslint-disable-next-line react-compiler/react-compiler
// eslint-disable-next-line react-hooks/exhaustive-deps
[value],
);
Expand Down Expand Up @@ -94,6 +95,7 @@ function FileUploadBinaryParam({ onChangeValue }: BinaryParamProps) {
onChangeValue(Binary.fromBytes(new Uint8Array(arrayBuffer)));
}
},
// eslint-disable-next-line react-compiler/react-compiler
// eslint-disable-next-line react-hooks/exhaustive-deps
[arrayBuffer],
);
Expand Down
1 change: 1 addition & 0 deletions src/components/param/compact.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,7 @@ export function CompactParam({
() => {
onChangeValue(parsedValue);
},
// eslint-disable-next-line react-compiler/react-compiler
// eslint-disable-next-line react-hooks/exhaustive-deps
[parsedValue],
);
Expand Down
1 change: 1 addition & 0 deletions src/components/param/enum.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,7 @@ export function INTERNAL_EnumParam({
() => {
onChangeValue({ type: key, value });
},
// eslint-disable-next-line react-compiler/react-compiler
// eslint-disable-next-line react-hooks/exhaustive-deps
[key, value],
);
Expand Down
1 change: 1 addition & 0 deletions src/components/param/options.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@ export function OptionParam<T>({
() => {
onChangeValue(derivedValue);
},
// eslint-disable-next-line react-compiler/react-compiler
// eslint-disable-next-line react-hooks/exhaustive-deps
[derivedValue],
);
Expand Down
1 change: 1 addition & 0 deletions src/components/param/primitive.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -129,6 +129,7 @@ export function PrimitiveParam({
() => {
onChangeValue(parsedValue);
},
// eslint-disable-next-line react-compiler/react-compiler
// eslint-disable-next-line react-hooks/exhaustive-deps
[parsedValue],
);
Expand Down
1 change: 1 addition & 0 deletions src/components/param/sequence.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -95,6 +95,7 @@ export function SequenceParam<T>({
() => {
onChangeValue(derivedValue);
},
// eslint-disable-next-line react-compiler/react-compiler
// eslint-disable-next-line react-hooks/exhaustive-deps
[derivedValue],
);
Expand Down
1 change: 1 addition & 0 deletions src/components/param/struct.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,7 @@ function INTERNAL_StructParam<T extends Record<string, unknown>>({
() => {
onChangeValue(derivedStruct);
},
// eslint-disable-next-line react-compiler/react-compiler
// eslint-disable-next-line react-hooks/exhaustive-deps
[derivedStruct],
);
Expand Down
1 change: 1 addition & 0 deletions src/components/param/tuple.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,7 @@ function INTERNAL_TupleParam<T extends Array<unknown>>({
() => {
onChangeValue(derivedTuple);
},
// eslint-disable-next-line react-compiler/react-compiler
// eslint-disable-next-line react-hooks/exhaustive-deps
[derivedTuple],
);
Expand Down
2 changes: 2 additions & 0 deletions src/routes/_layout/extrinsics.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -252,6 +252,7 @@ function CallParam({
setCallDataInput(searchCallData, true);
}
},
// eslint-disable-next-line react-compiler/react-compiler
// eslint-disable-next-line react-hooks/exhaustive-deps
[],
);
Expand All @@ -264,6 +265,7 @@ function CallParam({
setCallDataInput(callDataHex);
}
},
// eslint-disable-next-line react-compiler/react-compiler
// eslint-disable-next-line react-hooks/exhaustive-deps
[callDataHex],
);
Expand Down

0 comments on commit b4cb126

Please sign in to comment.