45

GitHub - snakajima/firebase-startup-kit

 4 years ago
source link: https://github.com/snakajima/firebase-startup-kit
Go to the source link to view the article. You can view the picture content, updated content and better typesetting reading experience. If the link is broken, please click the button below to view the snapshot at that time.

README.md

Purpose

This is a start-up kit for a Firebase web project, which uses React.js and Material-UI.

Instruction

  1. Git clone this repository
  2. Run "npm install firebase-tools -g" to install firebase tools.
  3. Run "npm install" once to get necessary node modules.
  4. Run "npm install" once in the functions directory as well.
  5. Open the firebase console (from https://firebase.google.com) and add a project
  6. From the dashboard of this project, add an app and choose "web" (</>).
  7. From the setting of this app, choose "Config" (in Firebase SDK snippet)
  8. Copy the config file, and paste into src/config.js file.
  9. Replace the word "skelton-us" in .firebaserc file with your Firebase project name.
  10. Open the firebase console, and create a Cloud Firestore (make it "secure" for now).

Available Scripts

In the project directory, you can run:

npm start

Runs the app in the development mode.
Open http://localhost:3000 to view it in the browser.

The page will reload if you make edits.
You will also see any lint errors in the console.

npm run build

Builds the app for production to the build folder.
It correctly bundles React in production mode and optimizes the build for the best performance.

The build is minified and the filenames include the hashes.
Your app is ready to be deployed!

firebase deploy

Deploys the app to the Firebase cloud. You need to run "npm run build" before the deployment.


About Joyk


Aggregate valuable and interesting links.
Joyk means Joy of geeK