Skip to content
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

+ Typescript Cleanup #118

Merged
merged 2 commits into from
Sep 26, 2023
Merged

+ Typescript Cleanup #118

merged 2 commits into from
Sep 26, 2023

Conversation

ryuzaki01
Copy link
Contributor

this will cleanup most of the typescript issue in the example folder

@ryuzaki01 ryuzaki01 requested a review from a team as a code owner September 16, 2023 11:27
@@ -9,7 +9,7 @@ const XmtpContext = createContext<{
setClient: () => {},
});
export const useXmtp = () => useContext(XmtpContext);
export function XmtpContextProvider({ children }) {
export const XmtpContextProvider: FC<any> = ({ children }) => {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

i think FC<PropsWithChildren> would work better here

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ahhh yes, I missed that..

type Props = {
children: ReactNode
}
export const XmtpContextProvider: FC<Props> = ({ children }) => {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

FYI, PropsWithChildren is an official export from react

@nplasterer nplasterer merged commit b05bf8f into xmtp:main Sep 26, 2023
1 of 2 checks passed
@github-actions
Copy link
Contributor

🎉 This PR is included in version 1.16.7 🎉

The release is available on:

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants