diff --git a/web/.prettierrc b/web/.prettierrc index 0967ef42..bd18729f 100644 --- a/web/.prettierrc +++ b/web/.prettierrc @@ -1 +1,7 @@ -{} +{ + "tabWidth": 2, + "useTabs": false, + "semi": false, + "trailingComma": "es5", + "singleQuote": true +} diff --git a/web/README.md b/web/README.md index 30869057..9902ae97 100644 --- a/web/README.md +++ b/web/README.md @@ -8,6 +8,6 @@ ## Formatting -Before committing, run `npx prettier --write . ` +Before committing, run `npm run format` to format your code. Recommended: Use a [Prettier editor integration](https://prettier.io/docs/en/editors.html) to automatically format on save diff --git a/web/components/convert-kit-email-form.tsx b/web/components/convert-kit-email-form.tsx index 00c0e788..4d8f06c3 100644 --- a/web/components/convert-kit-email-form.tsx +++ b/web/components/convert-kit-email-form.tsx @@ -1,6 +1,6 @@ export const ConvertKitEmailForm = () => { - return
; -}; + return +} const convertkitHTML = { __html: ` @@ -23,4 +23,4 @@ const convertkitHTML = { `, -}; +} diff --git a/web/components/hero.tsx b/web/components/hero.tsx index 6b3d3475..07df912f 100644 --- a/web/components/hero.tsx +++ b/web/components/hero.tsx @@ -1,13 +1,13 @@ -import { Popover } from "@headlessui/react"; -import { ConvertKitEmailForm } from "./convert-kit-email-form"; +import { Popover } from '@headlessui/react' +import { ConvertKitEmailForm } from './convert-kit-email-form' const navigation = [ { - name: "About", - href: "https://mantic.notion.site/About-Mantic-Markets-09bdde9044614e62a27477b4b1bf77ea", + name: 'About', + href: 'https://mantic.notion.site/About-Mantic-Markets-09bdde9044614e62a27477b4b1bf77ea', }, - { name: "Simulator", href: "https://simulator.mantic.markets" }, -]; + { name: 'Simulator', href: 'https://simulator.mantic.markets' }, +] export const Hero = () => { return ( @@ -78,5 +78,5 @@ export const Hero = () => { - ); -}; + ) +} diff --git a/web/next.config.js b/web/next.config.js index 3dd7ef15..8b61df4e 100644 --- a/web/next.config.js +++ b/web/next.config.js @@ -1,4 +1,4 @@ /** @type {import('next').NextConfig} */ module.exports = { reactStrictMode: true, -}; +} diff --git a/web/package.json b/web/package.json index adca4348..189a19c8 100644 --- a/web/package.json +++ b/web/package.json @@ -5,7 +5,8 @@ "dev": "next dev", "build": "next build && next export", "start": "next start", - "lint": "next lint" + "lint": "next lint", + "format": "npx prettier --write ." }, "dependencies": { "@headlessui/react": "^1.4.2", diff --git a/web/pages/_app.tsx b/web/pages/_app.tsx index 185a168e..8e5360d9 100644 --- a/web/pages/_app.tsx +++ b/web/pages/_app.tsx @@ -1,8 +1,8 @@ -import "tailwindcss/tailwind.css"; -import type { AppProps } from "next/app"; +import 'tailwindcss/tailwind.css' +import type { AppProps } from 'next/app' function MyApp({ Component, pageProps }: AppProps) { - return