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
package main | |
import ( | |
tem "github.com/scaleway/scaleway-sdk-go/api/tem/v1alpha1" | |
"github.com/scaleway/scaleway-sdk-go/scw" | |
) | |
func main() { | |
// Read those from env | |
SCW_ACCESS_KEY := "SCW_ACCESS_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
import React from 'react'; | |
import {BottomSheetScrollView} from '@gorhom/bottom-sheet'; | |
import {FlashList, FlashListProps} from '@shopify/flash-list'; | |
type Props<T> = Omit<FlashListProps<T>, 'renderScrollComponent'>; | |
const BottomSheetFlashList = <T,>(props: Props<T>) => { | |
return ( | |
<FlashList<T> | |
{...props} |
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
CREATE ROLE crud_user LOGIN PASSWORD 'thisissecretpassword'; | |
ALTER DEFAULT PRIVILEGES IN SCHEMA public | |
GRANT SELECT, INSERT, UPDATE, DELETE ON TABLES TO crud_user; | |
GRANT SELECT, INSERT, UPDATE, DELETE ON ALL TABLES IN SCHEMA public TO crud_user; | |
GRANT USAGE, SELECT ON ALL SEQUENCES IN SCHEMA public TO crud_user; | |
ALTER DEFAULT PRIVILEGES IN SCHEMA public | |
GRANT USAGE, SELECT ON SEQUENCES TO crud_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
{ | |
"go.toolsManagement.autoUpdate": true, | |
"go.useLanguageServer": true, | |
"go.lintTool": "golangci-lint", | |
"go.lintFlags": ["--fast"], | |
"go.addTags": { | |
"options": "json=" | |
}, | |
"[go]": { | |
"editor.defaultFormatter": "golang.go", |
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 { isEqual } from 'lodash'; | |
import React from 'react'; | |
import { Dimensions, StyleSheet, ViewStyle } from 'react-native'; | |
import MapView, { LatLng, MapViewProps, Marker, PROVIDER_GOOGLE } from 'react-native-maps'; | |
interface P extends MapViewProps { | |
coordinate?: LatLng; | |
onChange?: (coordinate: LatLng) => void; | |
} | |
const { width } = Dimensions.get('window'); |
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 _mmNumbers = { | |
'0': '၀', | |
'1': '၁', | |
'2': '၂', | |
'3': '၃', | |
'4': '၄', | |
'5': '၅', | |
'6': '၆', | |
'7': '၇', | |
'8': '၈', |
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
FROM golang:1.12 as builder | |
ADD . /app/api | |
WORKDIR /app/api | |
RUN go mod download | |
RUN CGO_ENABLED=0 GOOS=linux go build -v -o api | |
FROM alpine |
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 { debounce } from 'lodash'; | |
import React from 'react'; | |
import { | |
Dimensions, | |
StyleSheet, | |
TouchableOpacity, | |
View, | |
ViewStyle, | |
} from 'react-native'; | |
import { BarCodeType, Point, RNCamera, Size } from 'react-native-camera'; |
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 { | |
Dimensions, | |
Image, | |
ListRenderItemInfo, | |
StyleSheet, | |
Text, | |
TouchableWithoutFeedback, | |
View, | |
ViewStyle, |
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 { throttle } from 'lodash'; | |
import React from 'react'; | |
import { ActivityIndicator, FlatList, ListRenderItem } from 'react-native'; | |
import { RNFirebase } from 'react-native-firebase'; | |
import { Subject, Subscription } from 'rxjs'; | |
type Query = RNFirebase.firestore.Query; | |
type DocumentSnapshot = RNFirebase.firestore.DocumentSnapshot; | |
interface P<T> { |
NewerOlder