-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Convert to TypeScript and add ESLint/Prettier 🤌 (#3)
Among the conversion and linting there are additional changes included: * Set proper useEffect deps * Header: Fix initial arrow animation (unnecessary animating happened under the Splash) * Header: Remove unnecessary animation props that didn't have effect and do minor animation tweaks * Header: Remove the marquee "transition" key since it isn't a variant * Header: Rename NavItem -> HeaderNavItem * Header: Fix useMedia ssr error * Fix vercel/next.js#65161 * Relocate locomotive-scroll wrapper to components with proper types * Add build step script for Vercel, not active currently * Figure: Don't spread props since the invalid blur* attrs could be applied (vercel/next.js#56511) * Figure: Remove unnecessary props and add ones that could be needed * Figure: Add alt text to video also * Tweak tokens * Slightly tweak some content strings and styles * Refactor unnecessary stuff away from useInView hook * Bunch of file extension changes and sort tweaks * Relocate and fix component script * Sort keys, jsx props and destructured keys * Sitemap: Better key for projects * utility.js -> utils.ts
- Loading branch information
1 parent
8db0be5
commit 168d5fb
Showing
195 changed files
with
7,673 additions
and
6,652 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,52 @@ | ||
{ | ||
"$schema": "https://json.schemastore.org/eslintrc", | ||
"extends": [ | ||
"next/core-web-vitals", | ||
"plugin:import/recommended", | ||
"plugin:prettier/recommended", | ||
"plugin:@typescript-eslint/recommended", | ||
"plugin:typescript-sort-keys/recommended" | ||
], | ||
"plugins": [ | ||
"sort-imports-es6-autofix", | ||
"sort-keys-fix", | ||
"sort-destructure-keys" | ||
], | ||
"rules": { | ||
"@typescript-eslint/consistent-type-imports": [ | ||
"error", | ||
{ | ||
"prefer": "type-imports", | ||
"fixStyle": "inline-type-imports" | ||
} | ||
], | ||
"@typescript-eslint/consistent-type-exports": "error", | ||
"@typescript-eslint/prefer-nullish-coalescing": "error", | ||
"@typescript-eslint/no-explicit-any": "off", | ||
"import/newline-after-import": "error", | ||
"sort-imports-es6-autofix/sort-imports-es6": [ | ||
2, | ||
{ | ||
"ignoreCase": true | ||
} | ||
], | ||
"sort-keys-fix/sort-keys-fix": "error", | ||
"sort-destructure-keys/sort-destructure-keys": [ | ||
2, | ||
{ "caseSensitive": false } | ||
], | ||
"react/no-unescaped-entities": "off", | ||
"react/jsx-sort-props": "error" | ||
}, | ||
"overrides": [ | ||
{ | ||
"files": ["*.ts", "*.tsx"], | ||
"parser": "@typescript-eslint/parser", | ||
"parserOptions": { | ||
"ecmaVersion": "latest", | ||
"project": ["tsconfig.json"], | ||
"sourceType": "module" | ||
} | ||
} | ||
] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
import type { AppProps as NextAppProps } from 'next/app'; | ||
|
||
export interface AppProps extends Omit<NextAppProps, 'router'> {} | ||
|
||
export interface AppStateProps { | ||
detect: { | ||
[key: string]: boolean; | ||
}; | ||
html: Document['documentElement']; | ||
loading: boolean; | ||
loadingEnd: boolean; | ||
transition: boolean | 'template'; | ||
transitionInitial: boolean; | ||
} | ||
|
||
export interface AppContextProps { | ||
appState: AppStateProps; | ||
setLoadingEnd: (value: AppStateProps['loadingEnd']) => void; | ||
setTransition: (value: AppStateProps['transition']) => void; | ||
setTransitionInitial: (value: AppStateProps['transitionInitial']) => void; | ||
} |
Oops, something went wrong.