-
Notifications
You must be signed in to change notification settings - Fork 2.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fix(storage): expose static types for modular API #8322
Conversation
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
495b195
to
0b50021
Compare
packages/storage/lib/index.js
Outdated
// import { STATICS } from '@react-native-firebase/storage'; | ||
export const statics = { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I did a little fixup here to make this work (by adding the export here and removing the export below)
but the other two statics PRs would not have the export
here, they would leave it in modular only
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
good catch 👍 . I've also updated tests for static properties which I've done for others as well (using intellisense to pick up type properties as POC 😄 )
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
actually, I think we should remove the static export from here, it should be from modular only in my view
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
So my fixup here quieted one error but I wasn't sure on it - and I like your way of thinking better
Action - the export here should be removed, and statics should just go into the registry function for namespace attachment
Huh - that appears to have caused a real issue:
enhancement thought - but not on this PR - need to get those e2e tests in to typescript and have the type check as part of our lint checks which are fast enough to run locally and faster in CI |
…n namespaced exports
@russellwheatley I pushed a maybe-final commit here that adjusts this types PR to follow your thinking on the other two
...and I adjusted the use of statics internally so they handle the new export style from the statics-file so it should pass e2e now what do you think? |
@mikehardy - yes, we're in agreement 🙏. Should hopefully go green now, there was one remaining pesky default export in that StorageReference file. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
A thing of beauty
Description
Related issues
Release Summary
Checklist
Android
iOS
e2e
tests added or updated inpackages/\*\*/e2e
jest
tests added or updated inpackages/\*\*/__tests__
Test Plan
Think
react-native-firebase
is great? Please consider supporting the project with any of the below:React Native Firebase
andInvertase
on Twitter