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
# If you come from bash you might have to change your $PATH. | |
# export PATH=$HOME/bin:/usr/local/bin:$PATH | |
# Path to your oh-my-zsh installation. | |
export ZSH="/Users/jlozovei/.oh-my-zsh" | |
# Set name of the theme to load --- if set to "random", it will | |
# load a random theme each time oh-my-zsh is loaded, in which case, | |
# to know which specific one was loaded, run: echo $RANDOM_THEME | |
# See https://github.com/robbyrussell/oh-my-zsh/wiki/Themes |
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
# Get codebase total lines (all files) | |
git ls-files | xargs wc -l | |
# Get codebase total lines (ignore files with extension) | |
git ls-files -- . ':!:*.md' | xargs wc -l | |
# Get codebase total lines (files matching a extension) | |
git ls-files -- '*.js' | xargs wc -l | |
# Get total lines of a codebase, by user |
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
{ | |
"theme": "Ayu Dark", | |
"base_keymap": "SublimeText", | |
"ui_font_size": 18, | |
"buffer_font_size": 18 | |
} |
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
import { useState, useEffect } from 'react'; | |
import './styles.css'; | |
const stages = { | |
unmounted: 'unmounted', | |
entering: 'entering', | |
entered: 'entered', | |
completed: 'completed', | |
exiting: 'exiting', |
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
// context/index.js | |
import { useReducer, useEffect, useMemo, createContext } from 'react'; | |
import { reducer1, reducer2, reducer3 } from './reducers'; | |
const Context = createContext({}); | |
const STORAGE_KEY = 'my_awesome_storage' | |
const defaultState = { | |
user: { |
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
# Clean cache and hard stop | |
docker system prune -a |
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
:root { | |
--columns: 16; | |
} | |
.grid { | |
grid-template-columns: repeat(var(--columns), [col-start] 1fr); | |
} |
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
# run a single spec with jest | |
# -- replace <spec> with the spec's name (i.e. Button) | |
jest -t='<describeString> <itString>' | |
npm run test -- -t '<describeString> <itString>' | |
# run a single spec using file path | |
# -- replace <path> with the file's path (i.e. src/tests/test.js) | |
jest <path> | |
# clear cache |
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
{ | |
"window.title": "${dirty} ${activeEditorMedium}${separator}${rootName}", | |
"editor.fontSize": 18, | |
"editor.tabSize": 2, | |
"editor.multiCursorModifier": "ctrlCmd", | |
"editor.snippetSuggestions": "top", | |
"editor.formatOnPaste": false, | |
"editor.formatOnSave": true, | |
"editor.codeActionsOnSave": { |
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
import { Html, Head, Main, NextScript } from 'next/document'; | |
import { ServerStyleSheet } from 'styled-components'; | |
export default function Document() { | |
const getInitialProps = async (ctx) => { | |
const sheet = new ServerStyleSheet(); | |
const originalRenderPage = ctx.renderPage; | |
try { | |
ctx.renderPage = () => |
NewerOlder