Skip to content
This is a fork of the MPA scorecard app developed by Peter Lord.
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
data-fetchers
public
src
.gitignore
README.md
create-react-app-README.md
package-lock.json
package.json
yarn.lock

README.md

This project was bootstrapped with Create React App. See the bootstrapped README for more info.

Table of Contents

Installation

git clone https://github.com/pmlord/legislative-scorecard.git
cd legislative-scorecard
yarn install

A note on Yarn

yarn is a drop-in replacement for npm, and is what you’ll see documented throughout this README. You can install it with npm

npm install --global yarn

or see their documentation for alternatives such as Homebrew and MacPorts.

Develop

yarn start

The dev server will run on http://localhost:3000

HTTPS

HTTPS=true yarn start

Environments

Within the source code, you can refer to process.env.REACT_APP_ENV for the current environment. The value may be 'development', 'staging', and 'production'. These are set with yarn start, yarn build:staging, and yarn build:production, respectively.

This is an extension of create-react-app's NODE_ENV. process.env.NODE_ENV is still available, but process.env.REACT_APP_ENV should be used instead.

Build

yarn build:staging
yarn build:production
yarn build  # alias for build:production

Deploy

Hosted on AWS with S3, CloudFront, and Route-53.

To deploy, you'll need to install the AWS-CLI and have the appropriate AWS credentials configured.

Deploy whatever's in the /build/ directory:

yarn deploy:staging     # http://
yarn deploy:production  # http://
yarn deploy             # alias for deploy:production

Build & deploy:

yarn build:deploy:staging     # http
yarn build:deploy:production  # http

Credits

The project is a fork of the Legislative Scorecard project created by Peter Lord with design from Shannon McHarg of Efficient Interaction.

You can’t perform that action at this time.