mirror of
https://github.com/TheRealOwenRees/echecsfrance.git
synced 2026-07-23 04:26:57 +00:00
Fix lint errors
This commit is contained in:
@@ -2,6 +2,7 @@
|
|||||||
"extends": [
|
"extends": [
|
||||||
"next",
|
"next",
|
||||||
"next/core-web-vitals",
|
"next/core-web-vitals",
|
||||||
|
"plugin:react-hooks/recommended",
|
||||||
"prettier"
|
"prettier"
|
||||||
],
|
],
|
||||||
"globals": {
|
"globals": {
|
||||||
|
|||||||
@@ -41,7 +41,8 @@ export default async function RootLayout({
|
|||||||
children: ReactNode;
|
children: ReactNode;
|
||||||
params: { locale?: string };
|
params: { locale?: string };
|
||||||
}) {
|
}) {
|
||||||
const locale = useLocale();
|
// eslint-disable-next-line react-hooks/rules-of-hooks
|
||||||
|
const locale = useLocale(); // This hook IS allowed since it's stateless
|
||||||
|
|
||||||
// Show a 404 error if the user requests an unknown locale
|
// Show a 404 error if the user requests an unknown locale
|
||||||
if (params.locale !== undefined && params.locale !== locale) {
|
if (params.locale !== undefined && params.locale !== locale) {
|
||||||
|
|||||||
@@ -31,7 +31,7 @@ type TournamentsDisplayProps = {
|
|||||||
tournaments: Tournament[];
|
tournaments: Tournament[];
|
||||||
};
|
};
|
||||||
|
|
||||||
export default async function TournamentsDisplay({
|
export default function TournamentsDisplay({
|
||||||
tournaments,
|
tournaments,
|
||||||
}: TournamentsDisplayProps) {
|
}: TournamentsDisplayProps) {
|
||||||
useHydrateAtoms([[tournamentsAtom, tournaments]]);
|
useHydrateAtoms([[tournamentsAtom, tournaments]]);
|
||||||
|
|||||||
Generated
+659
-369
File diff suppressed because it is too large
Load Diff
@@ -51,6 +51,7 @@
|
|||||||
"eslint": "8.45.0",
|
"eslint": "8.45.0",
|
||||||
"eslint-config-next": "^13.4.12",
|
"eslint-config-next": "^13.4.12",
|
||||||
"eslint-config-prettier": "^8.8.0",
|
"eslint-config-prettier": "^8.8.0",
|
||||||
|
"eslint-plugin-react-hooks": "^5.0.0-canary-7118f5dd7-20230705",
|
||||||
"prettier": "3.0.0",
|
"prettier": "3.0.0",
|
||||||
"prettier-plugin-tailwindcss": "^0.4.1"
|
"prettier-plugin-tailwindcss": "^0.4.1"
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user