Member-only story
How to Create and Deploy a Serverless React App
TL;DR:Infrastructure-Components let you create, start, and deploy a Serverless React App easily. The component <SinglePageApp/>
does all the technical configuration for you and enables you to concentrate on writing the business logic of your App.

Infrastructure-Components provide an easy way to create React applications without struggling with the configuration. There is no need to manually configure Webpack, Babel, and Serverless anymore!
The following piece of code is a complete Serverless React App that you can build, start (locally), or deploy (to AWS) with a single command.
Getting Started
Get your customized boilerplate code
Infrastructure-Components let you create your customized boilerplate code with a few clicks.
- Specify a name for your React app (like
myapp
) and a name of an environment, (e.g.dev
) - Download and unpack your customized boilerplate code
- Install all the dependencies, run:
npm install
Example Project
Alternatively, have a look at this GitHub repository. It contains an example that you can fork or clone and simply run npm install
.
Manual Installation
You created your app with create-react-app
or started it with npm init
? No problem. You can setup Infrastructure-Components with the following steps:
1 . The library infrastructure-components contains the React components that you can use directly in your application’s source code.
npm install --save infrastructure-components
2 . The library infrastructure-scripts comprises the scripts required of building, starting, and deploying the app. For this lib contains many tools that you only need during development/deployment, install this library as devDependency
. You need to install serverless
and…