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
const contacts = {}; | |
let prospectiveUsersCache = {}; | |
const isZiinaUser = (phoneNumber) => { | |
return false; | |
}; | |
const syncContacts = (userId, phoneNumbers) => { | |
contacts[userId] = phoneNumbers; |
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
type Modifiers = { | |
[key: string]: any, | |
} | |
export const toClassNames = (base: string, modifiers: Modifiers = {}): string => { | |
const mods = Object | |
.entries(modifiers) | |
.filter(([, value]) => !!value) | |
.map(([key, _]) => `${base}--${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
$baseline: 6px !default; | |
$xxs: $baseline * 0.5 !default; // 3px | |
$xs: $baseline * 1 !default; // 6px | |
$s: $baseline * 2 !default; // 12px | |
$m: $baseline * 4 !default; // 24px | |
$l: $baseline * 8 !default; // 48px | |
$xl: $baseline * 16 !default; // 96px | |
$xxl: $baseline * 32 !default; // 192px |
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, {memo, useCallback, useEffect, useRef, useState} from 'react'; | |
import formatDistanceToNow from 'date-fns/formatDistanceToNow'; | |
type TimeAgoProps = { | |
timestamp: number, | |
} | |
const UPDATE_DELTA_MS = 10000; // 10s | |
const getTimeAgo = (timestamp: number): string => `${formatDistanceToNow(new Date(timestamp))} ago`; |
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 range from "lodash.range"; | |
type PageRangeArgs = { | |
size?: number, | |
last: number, | |
current: number, | |
} | |
type PageRangeReturnValue = number[]; |
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 { Pressable, Text } from 'react-native'; | |
import { useDoubleTapHandler } from './useDoubleTapHandler'; | |
const UsageExample = () => { | |
const onPressHandler = useDoubleTapHandler(); | |
const onPress = () => { | |
onPressHandler({ | |
onSinglePress: () => console.log('Single Tap'), |
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
const punctuate = (items = []) => { | |
const amount = items.length; | |
return items.reduce((acc, item, index) => { | |
if (amount === 1) { | |
return item; | |
} | |
return index === (amount - 1) | |
? `${acc} and ${item}` |
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
Calculating region TransACT... | |
http://serv-cache.alib.sg3.yahoo.com:4080/tv/1.0/channels;output=json;location=au;provider=0;region=128;begin=1498536768;end=1498547588 | |
92.66KB in 0.763975s | |
Calculating region Foxtel... | |
http://serv-cache.alib.sg3.yahoo.com:4080/tv/1.0/channels;output=json;location=au;provider=0;region=168;begin=1498536768;end=1498547588 | |
485.207KB in 1.202114s | |
Calculating region Optus TV feat. Foxtel... | |
http://serv-cache.alib.sg3.yahoo.com:4080/tv/1.0/channels;output=json;location=au;provider=0;region=192;begin=1498536768;end=1498547588 | |
273.661KB in 1.413676s | |
Calculating region Fetch... |
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
<?php | |
return [ | |
/** | |
* 2 Byte unicode characters. | |
*/ | |
'2byte' => [ | |
'À','Á','Â','Ã','Ä','Å','Ă','Æ','Ç','È','É','Ê','Ë','Ì','Í','Î','Ï','Ð', | |
'Ñ','Ò','Ó','Ô','Õ','Ö','Ő','Ø','Ș','Ț','Ù','Ú','Û','Ü','Ű','Ý','Þ','ß', | |
'à','á','â','ã','ä','å','ă','æ','ç','è','é','ê','ë','ì','í','î','ï','ð', |
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
2 byte unicode: | |
--------------- | |
À Á Â Ã Ä Å Ă Æ Ç È É Ê Ë Ì Í Î Ï Ð Ñ Ò Ó Ô Õ Ö Ő Ø Ș Ț Ù Ú Û Ü Ű Ý Þ ß à á â ã | |
ä å ă æ ç è é ê ë ì í î ï ð ñ ò ó ô õ ö ő ø ș ț ù ú û ü ű ý þ ÿ أ ب ت ث ج ح خ د | |
ذ ر ز س ش ص ض ط ظ ع غ ف ق ك ل م ن ه و ي α β γ δ ε ζ η θ ι κ λ μ ν ξ ο π ρ σ τ υ | |
φ χ ψ ω ά έ ί ό ύ ή ώ ς ϊ ΰ ϋ ΐ Α Β Γ Δ Ε Ζ Η Θ Ι Κ Λ Μ Ν Ξ Ο Π Ρ Σ Τ Υ Φ Χ Ψ Ω | |
Ά Έ Ί Ό Ύ Ή Ώ Ϊ Ϋ | |
3 byte unicode | |
-------------- |
NewerOlder