Clone or download this repo.
Before continuing make sure you already have a firebase + firestore setup up and running. If you haven't please get a setup up and running. Example to get up and running - Investec Firebase/Firestore Functions App
Create a Firebase App on the Firebase Console under project settings.
- You will be prompt to choose a platform. Choose web
- Tick box also setup firebase hosting
- Click on dropdown. Choose
Create a new site
- Skip through steps until you reach step 4) of creating a new site. Copy
site
value - In your project paste it your firebase.json file
- Skip to finish
- Under your created web application copy config found under the
Firebase SDK Setup
In your project root create a new file called .env.local
. Paste copied config in there. Structure data so it look like .env
. Env file should contain quotations or commas
.env
example:
value1=string
value2=string
We are adding the .local
so the file won't be pushed to github.
Install dependencies, in project root run npm install
Serve app with npm run serve
- Login to firebase
firebase login
- Link project to firebase project
firebase use --add
- Make sure in
firebase.json > hosting.site
matches the correct site name which can be found on the Hosting tab. - Make sure dependencies in installed
npm install
- Build app
npm run build
- Deploy App
firebase deploy
npm install
npm run serve
npm run build
npm run lint