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
// export default interface Entity { | |
// fid?: string; // firestoreId | |
// delYn?: string; | |
// ... | |
// } | |
import Entity from '@/models/Entity'; | |
import {ReactNativeFirebase} from '@react-native-firebase/app'; | |
import firestore, { | |
FirebaseFirestoreTypes, |
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
// Expo SDK40 | |
// expo-blur: ~8.2.2 | |
// expo-haptics: ~8.4.0 | |
// react-native-gesture-handler: ~1.8.0 | |
// react-native-reanimated: ^2.0.0-rc.0 | |
// react-native-safe-area-context: 3.1.9 | |
import React, { useState } from 'react'; | |
import { | |
Image, |
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
# Install brew | |
/usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)" | |
echo 'eval "$(/opt/homebrew/bin/brew shellenv)"' >> ~/.zprofile | |
eval "$(/opt/homebrew/bin/brew shellenv)" | |
# Install oh-my-zsh | |
sh -c "$(curl -fsSL https://raw.github.com/ohmyzsh/ohmyzsh/master/tools/install.sh)" | |
# Install nvm | |
mkdir ~/.nvm |
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
yarn && npx pod-install |
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
git branch | egrep "fix|refactor|feat|issue" | xargs git branch -D |
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
export default function useColor(theme: string) { | |
return (white, dark) => { | |
return theme !== 'dark' ? white : dark; | |
}; | |
} | |
const theme = useTheme(); | |
const color = useColor(theme); | |
// color: color('#fff', '#000') |
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 {useCallback, useState} from 'react'; | |
export interface TabProps { | |
tab: string; | |
openTab: (name: string) => void; | |
} | |
export default function useTabProps(initialTab?: string): TabProps { | |
const [tab, setTab] = useState<string>(initialTab); |
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 {useCallback, useState} from 'react'; | |
export interface ModalProps { | |
modal: string; | |
closeModal: () => void; | |
openModal: (name: string) => void; | |
} | |
export default function useModalProps(): ModalProps { | |
const [modal, setModal] = useState<string>(null); |
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
<StatusBar hidden={true} /> |
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 * as React from 'react'; | |
import { TouchableOpacity, Text } from 'react-native'; | |
import { useTheme } from '@react-navigation/native'; | |
function MyButton() { | |
const { colors } = useTheme(); | |
const styles = styleWithTheme(colors); | |
return ( | |
<TouchableOpacity style={styles.card}> |
NewerOlder