This file contains hidden or 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
Show hidden characters
{ | |
"env": { | |
"es2021": true, | |
"node": true | |
}, | |
"extends": ["eslint:recommended", "prettier"], | |
"parserOptions": { | |
"ecmaVersion": 12, | |
"sourceType": "module" | |
}, |
This file contains hidden or 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
module.exports = { | |
semi: false, // Print semicolons at the ends of statements. | |
trailingComma: 'es5', // Trailing commas where valid in ES5 (objects, arrays, etc.) | |
jsxBracketSameLine: false, // Put the > of a multi-line JSX element at the end of the last line | |
singleQuote: true, // Use single quotes instead of double quotes. | |
printWidth: 90, // Specify the line length that the printer will wrap on. | |
useTabs: true, // Indent lines with tabs instead of spaces. | |
tabWidth: 2, // Specify the number of spaces per indentation-level. | |
jsxSingleQuote: false, // Use single quotes instead of double quotes in JSX. | |
endOfLine: 'auto', // Maintain existing line endings |
This file contains hidden or 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
module.exports = { | |
root: true, | |
parser: '@typescript-eslint/parser', | |
parserOptions: { | |
ecmaVersion: 2020, | |
sourceType: 'module', | |
ecmaFeatures: { | |
jsx: true, | |
}, | |
}, |
This file contains hidden or 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
import { useState, useEffect } from "react"; | |
function getWindowDimensions() { | |
const { innerWidth: width, innerHeight: height } = window; | |
return { | |
width, | |
height, | |
}; | |
} |
This file contains hidden or 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
NEWLINE=$'\n' | |
PROMPT="%(?:%{$fg_bold[green]%}➜ :%{$fg_bold[red]%}➜ )" | |
PROMPT+=' %{$fg[purple]%}%/%{$reset_color%} $(git_prompt_info)${NEWLINE} ' | |
ZSH_THEME_GIT_PROMPT_PREFIX="%{$fg_bold[blue]%}git:(%{$fg[red]%}" | |
ZSH_THEME_GIT_PROMPT_SUFFIX="%{$reset_color%} " | |
ZSH_THEME_GIT_PROMPT_DIRTY="%{$fg[blue]%}) %{$fg[yellow]%}✗" | |
ZSH_THEME_GIT_PROMPT_CLEAN="%{$fg[blue]%})" |