def create_user_table():
"""Create the user table."""
try:
result = client.create_table(
TableName='user_table',
BillingMode='PAY_PER_REQUEST',
This file contains hidden or 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
| [ | |
| { | |
| "formatted_address": "211 S Greenwood Ave, Tulsa, OK 74120, United States", | |
| "geometry": { | |
| "location": { | |
| "lat": 36.1567677, | |
| "lng": -95.9840401 | |
| }, | |
| "viewport": { | |
| "south": 36.15535762010728, |
This file contains hidden or 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
| <!DOCTYPE html> | |
| <html lang=en> | |
| <head> | |
| <meta charset=utf-8 /> | |
| <meta content="IE=edge" http-equiv=X-UA-Compatible /> | |
| <meta content="width=device-width, initial-scale=1" name=viewport /> | |
| <title>Schedule | JAMstack_conf_sf</title> | |
| <meta content="A two day conference, and a day of workshops in San Francisco for learning to design, develop, & deploy modern web projects without servers." name=description /> | |
| <meta content="jamstack, pwa, progressive web apps, apis, api, react, reactjs, react.js, react conf, conference, conf, workshop, netlify, github, eventbrite, webpack, freecodecamp, redux, vue, vue.js, workshop, learn to code, learn to program, learn react, san francisco, learn programming, learn javascript, learn coding, code, coding, programming, software engineer, software developer, web development, development, engineering, coding bootcamp, javascript, open source, microservices, serverless, gatsby, contentful, angular, angular.js, angularjs" name=keywords /> | |
| <meta content="https://jamstackconf.com/sf" pr |
This file contains hidden or 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
| /* | |
| * | |
| * Starting today, get each date for the last N days. | |
| * | |
| */ | |
| const lastNDates = (n) => { | |
| let result = [] | |
| let d = new Date() | |
| let rd = `${d.getFullYear()}-${d.getMonth()+1}-${d.getDate()}` | |
| result.push(rd) |
This file contains hidden or 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
| def scan_all(dynamodb_table): | |
| """Return all items from a DynamoDB table by passing the table resource.""" | |
| results = [] | |
| has_items = True | |
| last_key = False | |
| while has_items: | |
| if last_key: | |
| data = dynamodb_table.scan(ExclusiveStartKey=last_key) | |
| else: | |
| data = dynamodb_table.scan() |
This file contains hidden or 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
| [ | |
| "alignContent", | |
| "alignItems", | |
| "alignSelf", | |
| "aspectRatio", | |
| "backfaceVisibility", | |
| "backgroundColor", | |
| "borderBottomColor", | |
| "borderBottomEndRadius", | |
| "borderBottomLeftRadius", |
This file contains hidden or 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
| response = client.copy_object( | |
| ACL='private'|'public-read'|'public-read-write'|'authenticated-read'|'aws-exec-read'|'bucket-owner-read'|'bucket-owner-full-control', | |
| Bucket='string', | |
| CacheControl='string', | |
| ContentDisposition='string', | |
| ContentEncoding='string', | |
| ContentLanguage='string', | |
| ContentType='string', | |
| CopySource='string' or {'Bucket': 'string', 'Key': 'string', 'VersionId': 'string'}, | |
| CopySourceIfMatch='string', |
This file contains hidden or 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
| render() { | |
| return ( | |
| <View> | |
| <View> | |
| <Text>Meditation Timer</Text> | |
| </View> | |
| <Text>10:00</Text> | |
| <Text>Close your eyes, relax, and breath naturally.</Text> | |
| <TouchableOpacity > | |
| <Text>Begin Session</Text> |
This file contains hidden or 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
| [ | |
| "AliceBlue ", | |
| "AntiqueWhite ", | |
| "Aqua ", | |
| "Aquamarine ", | |
| "Azure ", | |
| "Beige ", | |
| "Bisque ", | |
| "Black ", | |
| "BlanchedAlmond ", |
This file contains hidden or 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 sys | |
| import json | |
| input_file = sys.argv[len(sys.argv)-1] | |
| print('INPUT: ', input_file) | |
| output_file = input_file + '.csv' | |
| data = json.loads(open(input_file).read()) | |
| # print(",".join(list(data[0].keys()))) | |
| csv_headers = ",".join(list(data[0].keys())) | |
| with open(output_file, 'w') as f: | |
| f.write(csv_headers + '\n') |