AWS Launches One Click React Native Starter Project. Now available on GitHub, the Amazon Web Services (AWS), “Mobile React Native Starter App” gives the rapidly growing React Native ecosystem a simplified entry point. React Native, a new open-source technology for native iOS or Android app development, is based on JavaScript. It follows a “learn one, write anywhere” philosophy rather than the elusive, one-size fits all, cross-platform approach of “write once and run anywhere”. The bootstrap project provides all the support and context for a Pet Tracker app. It includes authorization, user registration, image storage and access to relevant APIs and database operations. This week’s blog post provided additional details about how this functionality is provided. AWS stated that the project includes a starter application that can run in a single click using the Deploy From GitHub button capabilities of AWS Mobile hub. [Click on the image to see a larger view.] Project architecture (Source AWS) “After deployment finishes the starter can then be run locally using either npm, yarn on iOS or Android. The project shows user sign-up and sign in flows, as well as MFA [multifactor authentication] for a ‘Pet Tracker application. This allows you to upload photos of your pets, along with some data (names, breeds, and genders). The photos are saved in an S3 bucket. Only the user can access the bucket. The records that correspond to these images are also stored in an Amazon DynamoDB database on a per user basis. This serverless infrastructure uses AWS Lambda and Amazon API Gateway to protect it. Developers who are interested in the starter project need to have an AWS account, NodeJS and npm, and the React Native CLI (command line-tool). The optional AWS CLI, Watchman file-watching and optional AWS CLI may also be helpful. The Pet Tracker app (Source : AWS). “In addition to the starter app, which you can modify to suit your needs, there are several Higher Order Components, (HOCs), that you can use to build your own application,” AWS stated. “For example, you can add the sign-up, sign in, and MFA portions to your application using the WithAuth HOC. There are also HOCs that allow secure storage access and API access. Although it can seem overwhelming to set up a full-fledged cloud app, AWS claims that once you import the project, it automatically configures.

  • Amazon Cognito User Pools & Federated Identities
  • Amazon API Gateway, AWS Lambda and Amazon DynamoDB
  • Amazon S3, including folder structures and bucket policies for private and public content
  • IAM roles and policy for Lambda execution
  • IAM roles and policy to govern the user roles that can access API routes and S3 buckets following authentication

The GitHub repository offers guidance on how to register and login components, access cloud REST APIs and store images and video in the AWS cloud. It also demonstrates how to modify cloud logic with Lambda.