diff --git a/.eslintrc.json b/.eslintrc.json index 21071b2..d3067d4 100644 --- a/.eslintrc.json +++ b/.eslintrc.json @@ -88,11 +88,5 @@ "next": ["const", "let", "var"] } ] - }, - "prettier/prettier": [ - "warn", - { - "endOfLine": "auto" - } - ] + } } diff --git a/.prettierrc.js b/.prettierrc.js new file mode 100644 index 0000000..b15bc8f --- /dev/null +++ b/.prettierrc.js @@ -0,0 +1,11 @@ +module.exports = { + printWidth: 80, + tabWidth: 2, + useTabs: false, + semi: true, + singleQuote: false, + trailingComma: 'all', + bracketSpacing: true, + arrowParens: 'always', + endOfLine: 'auto', +}; diff --git a/app/api/detail/route.ts b/app/api/detail/route.ts index e9e71aa..193f77c 100644 --- a/app/api/detail/route.ts +++ b/app/api/detail/route.ts @@ -26,7 +26,7 @@ const query = gql` `; // Function to handle GET requests -const handler = async(request: Request) => { +const handler = async (request: Request) => { const { searchParams } = new URL(request.url); const hash = searchParams.get("hash"); @@ -75,6 +75,6 @@ const handler = async(request: Request) => { }, ); } -} +}; export { handler as GET, handler as POST }; diff --git a/app/api/search/route.ts b/app/api/search/route.ts index c72d246..8097583 100644 --- a/app/api/search/route.ts +++ b/app/api/search/route.ts @@ -119,6 +119,6 @@ const handler = async (request: Request) => { }, ); } -} +}; export { handler as GET, handler as POST }; diff --git a/utils/index.ts b/utils/index.ts index 2392d6e..9f8b7f4 100644 --- a/utils/index.ts +++ b/utils/index.ts @@ -141,5 +141,5 @@ export const $env = { }, }; -export { Cookie } +export { Cookie }; export { Toast } from "./Toast";