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

Add @posthog/plugin-globals (0.0.1) #1

Closed
wants to merge 2 commits into from
Closed

Conversation

mariusandra
Copy link

Changes

  • Trying out the @posthog/plugin-globals package. No matter what we'll do with meta, we still have globals and will probably want some things to remain globals. This adds support for them.
    image

  • The plugin-globals project needs to be extended with other globals. Currently only posthog is there.

Checklist

  • Tests for new code

@mariusandra mariusandra requested a review from Twixes March 24, 2021 09:32
@Twixes
Copy link
Member

Twixes commented Mar 24, 2021

Thanks for the contribution!
I personally am okay with writing things like that. I am concerned however that anyone who does not work at PostHog may find the increased cognitive load of additional tsconfig and one more package discouraging from writing plugins with TypeScript or in general. It's also more thing to maintain for us. That's why I'd really really like all te definitions to be in the single plugin-scaffold package.

@mariusandra
Copy link
Author

Fair enough re: keeping things simpler. It's possible to do the same thing with the @posthog/plugin-scaffold package: PostHog/plugin-server#274 (comment) -- we'll just have to import it from a different source in posthog & plugin-server to not get the globals, but that shouldn't be too much work, considering it's a mostly one-off affair (a few times).

@mariusandra mariusandra deleted the add-globals branch March 25, 2021 08:51
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.

2 participants