-
Notifications
You must be signed in to change notification settings - Fork 185
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Refactor: trying to centralise all firebase types,
Which should make upgrading firebase easier
- Loading branch information
1 parent
2d79271
commit af3b2ab
Showing
36 changed files
with
377 additions
and
237 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -38,13 +38,14 @@ | |
"microbundle": "^0.12.4", | ||
"ts-jest": "^25", | ||
"tslint": "^5.16.0", | ||
"typescript": "^4.1.x" | ||
"typescript": "4.5.5" | ||
}, | ||
"homepage": "https://github.com/benwinding/react-admin-firebase", | ||
"email": "[email protected]", | ||
"license": "MIT", | ||
"scripts": { | ||
"build": "rm -rf dist && microbundle", | ||
"tsc-test": "tsc -p ./tsconfig.spec.json", | ||
"watch": "microbundle watch", | ||
"start-demo": "gulp start-demo", | ||
"start-emulator": "yarn firebase emulators:start --only firestore", | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
import { | ||
DocumentSnapshot, | ||
Query, | ||
QueryDocumentSnapshot, | ||
OrderByDirection | ||
} from '@firebase/firestore-types'; | ||
|
||
export type FireUser = firebase.User; | ||
export type FireApp = firebase.app.App; | ||
|
||
export type FireStorage = firebase.storage.Storage; | ||
export type FireStorageReference = firebase.storage.Reference; | ||
export type FireUploadTaskSnapshot = firebase.storage.UploadTaskSnapshot; | ||
export type FireUploadTask = firebase.storage.UploadTask; | ||
export type FireStoragePutFileResult = { | ||
task: FireUploadTask, | ||
taskResult: Promise<FireUploadTaskSnapshot>, | ||
downloadUrl: Promise<string>, | ||
} | ||
|
||
export type FireAuth = firebase.auth.Auth; | ||
export type FireAuthUserCredentials = firebase.auth.UserCredential; | ||
|
||
export type FireStore = firebase.firestore.Firestore; | ||
export type FireStoreBatch = firebase.firestore.WriteBatch; | ||
export type FireStoreTimeStamp = firebase.firestore.FieldValue; | ||
export type FireStoreDocumentRef = firebase.firestore.DocumentReference; | ||
export type FireStoreDocumentSnapshot = DocumentSnapshot; | ||
export type FireStoreCollectionRef = firebase.firestore.CollectionReference; | ||
export type FireStoreQueryDocumentSnapshot = QueryDocumentSnapshot; | ||
export type FireStoreQuery = Query; | ||
export type FireStoreQueryOrder = OrderByDirection; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.