Navigation Menu

Skip to content

Instantly share code, notes, and snippets.

@khalidbourhaba
khalidbourhaba / ConfirmSignUpScreen.js
Created November 19, 2019 14:17
Confirm Sign Up Screen
import React, { memo, useState } from 'react';
import { StyleSheet, Alert } from 'react-native';
import Background from '../components/Background';
import BackButton from '../components/BackButton';
import Logo from '../components/Logo';
import Header from '../components/Header';
import TextInput from '../components/TextInput';
import { theme } from '../core/theme';
import Button from '../components/Button';
import { confirmCodeValidator } from '../core/utils';
@khalidbourhaba
khalidbourhaba / .gitignore
Last active February 1, 2020 20:36
An example of a .gitignore file for a AWS Amplify Project
#amplify
amplify/\#current-cloud-backend
amplify/.config/local-*
amplify/mock-data
amplify/team-provider-info.json
amplify/backend/amplify-meta.json
amplify/backend/awscloudformation
build/
dist/
node_modules/
@khalidbourhaba
khalidbourhaba / index.js
Created May 24, 2020 22:01
lambda function
var aws = require('aws-sdk');
var ddb = new aws.DynamoDB();
exports.handler = async (event, context) => {
let date = new Date();
var tableName = 'User-oeky4hdaijah5b4deuz3c3l62u-dev' // or set dynamic via process.env
// If the required parameters are present, proceed
if (event.request.userAttributes.sub) {