https://github.com/hans00/firebase_webpack_template
https://github.com/hans00/firebase_webpack_template
firebase initial-cli template webpack
Last synced: 10 months ago
JSON representation
- Host: GitHub
- URL: https://github.com/hans00/firebase_webpack_template
- Owner: hans00
- Created: 2018-12-01T18:22:50.000Z (about 7 years ago)
- Default Branch: master
- Last Pushed: 2019-01-15T14:59:26.000Z (about 7 years ago)
- Last Synced: 2025-02-14T11:52:32.254Z (12 months ago)
- Topics: firebase, initial-cli, template, webpack
- Language: JavaScript
- Size: 88.9 KB
- Stars: 0
- Watchers: 3
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# %project_name%
%description%
---
## Firebase Setup
> Install `firebase-tools` first.
>
```sh
# Link project
firebase use --add
```
## Cloud Functions
> Code in directory `functions/src/events`.
>
### Code Usage
```js
import * as functions from 'firebase-functions'
import * as admin from 'firebase-admin'
export default functions.https.onRequest(async (req, res) => {
const { msg = '' } = req.body
res.send({msg})
})
```
### Command Usage
> In directory `functions`.
```sh
# For local Web API test
npm run serve
# For local cli test
npm run shell
# Deploy to Firebase
npm run deploy
```