mirror of
https://github.com/rjNemo/devbook_ts
synced 2026-06-06 02:36:39 +00:00
🔥 Firebase hosting (#8)
* init Firebase * add release step to github actions * fix syntax error * fix syntax error #2 * fix syntax error #3 * untrack firebase config files
This commit is contained in:
parent
9e30322ffc
commit
1e913e7760
5 changed files with 198 additions and 6 deletions
13
.github/workflows/deploy.yml
vendored
13
.github/workflows/deploy.yml
vendored
|
|
@ -25,3 +25,16 @@ jobs:
|
|||
with:
|
||||
start: yarn start
|
||||
wait-on: 'http://localhost:3000'
|
||||
release:
|
||||
if: ${{ github.ref == 'master' }}
|
||||
needs: test
|
||||
name: Release
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v2
|
||||
- name: Build
|
||||
run: yarn build
|
||||
- name: Install Firebase CLI tools
|
||||
run: yarn global add firebase-tools
|
||||
- name: Deploy
|
||||
run: firebase deploy --token ${{ secrets.FIREBASE_TOKEN }}
|
||||
|
|
|
|||
4
.gitignore
vendored
4
.gitignore
vendored
|
|
@ -28,3 +28,7 @@ yarn-debug.log*
|
|||
yarn-error.log*
|
||||
|
||||
.env
|
||||
.firebase
|
||||
firebase*json
|
||||
*rules
|
||||
.firebaserc
|
||||
|
|
@ -1,5 +0,0 @@
|
|||
{
|
||||
"name": "Using fixtures to represent data",
|
||||
"email": "hello@cypress.io",
|
||||
"body": "Fixtures are a great way to mock data for responses to routes"
|
||||
}
|
||||
117
firestore.indexes.json
Normal file
117
firestore.indexes.json
Normal file
|
|
@ -0,0 +1,117 @@
|
|||
{
|
||||
"indexes": [
|
||||
{
|
||||
"collectionGroup": "restaurants",
|
||||
"queryScope": "COLLECTION",
|
||||
"fields": [
|
||||
{
|
||||
"fieldPath": "category",
|
||||
"order": "ASCENDING"
|
||||
},
|
||||
{
|
||||
"fieldPath": "avgRating",
|
||||
"order": "DESCENDING"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"collectionGroup": "restaurants",
|
||||
"queryScope": "COLLECTION",
|
||||
"fields": [
|
||||
{
|
||||
"fieldPath": "category",
|
||||
"order": "ASCENDING"
|
||||
},
|
||||
{
|
||||
"fieldPath": "numRatings",
|
||||
"order": "DESCENDING"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"collectionGroup": "restaurants",
|
||||
"queryScope": "COLLECTION",
|
||||
"fields": [
|
||||
{
|
||||
"fieldPath": "category",
|
||||
"order": "ASCENDING"
|
||||
},
|
||||
{
|
||||
"fieldPath": "price",
|
||||
"order": "ASCENDING"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"collectionGroup": "restaurants",
|
||||
"queryScope": "COLLECTION",
|
||||
"fields": [
|
||||
{
|
||||
"fieldPath": "city",
|
||||
"order": "ASCENDING"
|
||||
},
|
||||
{
|
||||
"fieldPath": "avgRating",
|
||||
"order": "DESCENDING"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"collectionGroup": "restaurants",
|
||||
"queryScope": "COLLECTION",
|
||||
"fields": [
|
||||
{
|
||||
"fieldPath": "city",
|
||||
"order": "ASCENDING"
|
||||
},
|
||||
{
|
||||
"fieldPath": "numRatings",
|
||||
"order": "DESCENDING"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"collectionGroup": "restaurants",
|
||||
"queryScope": "COLLECTION",
|
||||
"fields": [
|
||||
{
|
||||
"fieldPath": "city",
|
||||
"order": "ASCENDING"
|
||||
},
|
||||
{
|
||||
"fieldPath": "price",
|
||||
"order": "ASCENDING"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"collectionGroup": "restaurants",
|
||||
"queryScope": "COLLECTION",
|
||||
"fields": [
|
||||
{
|
||||
"fieldPath": "price",
|
||||
"order": "ASCENDING"
|
||||
},
|
||||
{
|
||||
"fieldPath": "avgRating",
|
||||
"order": "DESCENDING"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"collectionGroup": "restaurants",
|
||||
"queryScope": "COLLECTION",
|
||||
"fields": [
|
||||
{
|
||||
"fieldPath": "price",
|
||||
"order": "ASCENDING"
|
||||
},
|
||||
{
|
||||
"fieldPath": "numRatings",
|
||||
"order": "DESCENDING"
|
||||
}
|
||||
]
|
||||
}
|
||||
],
|
||||
"fieldOverrides": []
|
||||
}
|
||||
63
tslint.json
Normal file
63
tslint.json
Normal file
|
|
@ -0,0 +1,63 @@
|
|||
{
|
||||
"rules": {
|
||||
"adjacent-overload-signatures": true,
|
||||
"ban-comma-operator": true,
|
||||
"no-namespace": true,
|
||||
"no-parameter-reassignment": true,
|
||||
"no-reference": true,
|
||||
"no-unnecessary-type-assertion": true,
|
||||
"label-position": true,
|
||||
"no-conditional-assignment": true,
|
||||
"no-construct": true,
|
||||
"no-duplicate-super": true,
|
||||
"no-duplicate-switch-case": true,
|
||||
"no-duplicate-variable": [
|
||||
true,
|
||||
"check-parameters"
|
||||
],
|
||||
"no-shadowed-variable": true,
|
||||
"no-empty": [
|
||||
true,
|
||||
"allow-empty-catch"
|
||||
],
|
||||
"no-floating-promises": true,
|
||||
"no-implicit-dependencies": true,
|
||||
"no-invalid-this": true,
|
||||
"no-string-throw": true,
|
||||
"no-unsafe-finally": true,
|
||||
"no-void-expression": [
|
||||
true,
|
||||
"ignore-arrow-function-shorthand"
|
||||
],
|
||||
"no-duplicate-imports": true,
|
||||
// Warn when an empty interface is defined. These are generally not useful.
|
||||
"no-empty-interface": {
|
||||
"severity": "warning"
|
||||
},
|
||||
"no-import-side-effect": {
|
||||
"severity": "warning"
|
||||
},
|
||||
"no-var-keyword": {
|
||||
"severity": "warning"
|
||||
},
|
||||
"triple-equals": {
|
||||
"severity": "warning"
|
||||
},
|
||||
"deprecation": {
|
||||
"severity": "warning"
|
||||
},
|
||||
"prefer-for-of": {
|
||||
"severity": "warning"
|
||||
},
|
||||
"unified-signatures": {
|
||||
"severity": "warning"
|
||||
},
|
||||
"prefer-const": {
|
||||
"severity": "warning"
|
||||
},
|
||||
"trailing-comma": {
|
||||
"severity": "warning"
|
||||
}
|
||||
},
|
||||
"defaultSeverity": "error"
|
||||
}
|
||||
Loading…
Reference in a new issue