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 WebView from 'react-native-webview'; | |
import React from 'react'; | |
export const Tips = () => { | |
const name = 'John Doe'; | |
const phoneNumber = '+72025550139'; | |
const amount = 100; | |
const uri = `https://pay.cloudtips.ru/a/borodach?name=${name}&sales=390&phone=${phoneNumber}&hidecomment=true${amount ? `&amount=${amount}` : ''}` | |
return ( |
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
// https://towardsdev.com/console-log-and-his-ninja-pals-4fc0863ad5f4 | |
// The count method can be used to display the number of times this message was shown on screen. | |
console.count(label); | |
// Instead of opening each and looking into them, we can have a flat tabular representation. | |
console.table([ | |
{ column1: 'row1', column2: 'row1' }, | |
{ column1: 'row2', column2: 'row2' }, | |
]); |
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
// https://medium.com/javascript-in-plain-english/powerful-typescript-tools-e1c7875fbb71 | |
type KeysToUnion<T> = keyof T; | |
type KeysToValue<T> = T[KeysToUnion<T>] | |
type KeysToTuple<T> = KeysToUnion<T>[] | |
type OmitPartial<T, K extends keyof T> = Omit<T, K> & { | |
[Key in K]?: T[Key] |