konkers / ff7run

BSD 3-Clause "New" or "Revised" License
1 stars 1 forks source link

FFVII Runs Website

Build Status

This is the code that backs the website ff7.run.

Code organization

The code in this repos is divided into 3 sections:

Development

Setup

System packages.

To develop, you'll need to install:

Global NPM dependencies.

Once installed, install the Typescript, Angular, and Firebase CLI utilities:

npm install -g typescript
npm install -g @angular/cli
npm install -g firebase-tools

Local NPM dependencies.

You'll also need to instal npm depedancies for the frontend and backend:

npm install
(cd projects/shared; npm install)
(cd functions; npm install)

Data Development

Data is stored in projects/shared/src/lib in JSON5 format. The files are converted to json for consumption by the frontend and backend using:

(cd projects/shared; npm run convert-data)

Frontend development

First build the backend and start the firebase emulators:

(cd functions; npm run build) && firebase emulators:start

Once that's started, start the angular dev server:

ng serve

The app will now be running at http://localhost:4200/. The app will automatically reload if you change any of the source files.

Running unit tests

Run ng test to execute the unit tests via Karma.

Running end-to-end tests

Run ng e2e to execute the end-to-end tests via Protractor.

Checking code before pushing

Run ng lint as well as npm run fmt:check before pushing code/sending a pull request.