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

chore: React Native for macOS support #162

Merged
merged 7 commits into from
Jan 24, 2024
Merged

Conversation

marandaneto
Copy link
Member

@marandaneto marandaneto commented Jan 23, 2024

Problem

React Native macOS support
https://github.com/microsoft/react-native-macos

I ran into the issue microsoft/react-native-macos#2053 which means all dependencies have to be installed, even if not used but it is dynamically imported via require, could not find an easy fix, only happens on RN macOS target.

Changes

Release info Sub-libraries affected

Bump level

  • Major
  • Minor
  • Patch

Libraries affected

  • All of them
  • posthog-web
  • posthog-node
  • posthog-react-native

Changelog notes

  • Added support for X

@marandaneto marandaneto requested a review from a team January 24, 2024 09:46
@marandaneto marandaneto marked this pull request as ready for review January 24, 2024 09:47
Copy link

@daibhin daibhin left a comment

Choose a reason for hiding this comment

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

Couple of tiny comments but looks good

export let posthog: PostHog | undefined;

export const posthogAsync: Promise<PostHog> = PostHog.initAsync(
'phc_pQ70jJhZKHRvDIL5ruOErnPy6xiAiWCqlL4ayELj4X8',
Copy link

Choose a reason for hiding this comment

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

Should we exclude this or change it to an env variable? Would not like the source to be polluted with data if people run the example

Copy link
Member Author

Choose a reason for hiding this comment

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

it's just a sample project with a testing org, it's nice to see events coming through, otherwise every time I run the examples, I have to change the apiKey before, rolling back the changes, its working quite well on the other SDKs as well but its only me testing it anyway.

Co-authored-by: David Newell <d.newell1@outlook.com>
@marandaneto marandaneto merged commit c14391c into main Jan 24, 2024
3 checks passed
@marandaneto marandaneto deleted the chore/macos-support branch January 24, 2024 13:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants