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 React from 'react' | |
import { StatusBar, Text, View } from 'react-native' | |
import { useSafeArea } from 'react-native-safe-area-context' | |
export function App() { | |
const safeAreaInsets = useSafeArea() | |
return ( | |
<View | |
style={{ |
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 { useEffect, useRef } from 'react' | |
export function useWhyDidYouUpdate(name: string, props: Record<string, any>) { | |
const latestProps = useRef(props) | |
useEffect(() => { | |
const allKeys = Object.keys({ ...latestProps.current, ...props }) | |
const changesObj: Record<string, { from: any; to: any }> = {} | |
allKeys.forEach(key => { |
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
lambda_functions=$(aws lambda list-functions | jq -r '.Functions' | jq -c '.[]') | |
for function in $lambda_functions | |
do | |
function_name=$(echo $function | jq -r '.FunctionName') | |
current_version=$(echo $function | jq -r '.Version') | |
lambda_versions=$(aws lambda list-versions-by-function --function-name $function_name | jq -r '.Versions' | jq -c '.[]') | |
for version in $lambda_versions | |
do |
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
# Xcode > Build Phases > Bundle React Native code and images | |
export NODE_BINARY=node | |
./react-native-xcode.sh |
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
(() => { | |
let count = 0; | |
function getAllButtons() { | |
return document.querySelectorAll('button.is-following') || []; | |
} | |
async function unfollowAll() { | |
const buttons = getAllButtons(); |
OlderNewer