@theholocron/holocron-plugin-posthog 5.0.0-alpha.270 → 5.0.0-alpha.272
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.d.mts +4 -2
- package/dist/index.mjs +3 -1
- package/package.json +6 -6
package/dist/index.d.mts
CHANGED
|
@@ -1,6 +1,8 @@
|
|
|
1
|
-
import { Analytics, AuthError, ResolveTokenInput, VerifyTokenFailure, VerifyTokenResult, VerifyTokenResult as VerifyTokenResult$1, VerifyTokenSuccess } from "@theholocron/cli";
|
|
1
|
+
import { Analytics, AuthError, PluginToken, ResolveTokenInput, VerifyTokenFailure, VerifyTokenResult, VerifyTokenResult as VerifyTokenResult$1, VerifyTokenSuccess } from "@theholocron/cli";
|
|
2
2
|
import { PostHogClient, PostHogClient as PostHogClient$1, PostHogClientOptions, PostHogProject, PostHogProjectsResponse, PostHogUser, createPostHogClient } from "@theholocron/posthog-client";
|
|
3
|
-
export declare const resolveToken: (
|
|
3
|
+
export declare const resolveToken: import("@theholocron/cli").TokenResolver;
|
|
4
|
+
/** Every token this plugin takes, for `holocron doctor tokens`. */
|
|
5
|
+
export declare const tokens: PluginToken[];
|
|
4
6
|
interface PostHogAnalyticsOptions {
|
|
5
7
|
/** PostHog instance host — pushed as NEXT_PUBLIC_POSTHOG_HOST. Default: https://app.posthog.com */
|
|
6
8
|
host?: string;
|
package/dist/index.mjs
CHANGED
|
@@ -8,6 +8,8 @@ const resolveToken = createResolveToken({
|
|
|
8
8
|
keyringService: "posthog",
|
|
9
9
|
errorMessage: "no PostHog personal API key found. Pass --token <KEY>, set HOLOCRON_POSTHOG_TOKEN / POSTHOG_PERSONAL_API_KEY, or run: holocron auth set posthog <phx_KEY>"
|
|
10
10
|
});
|
|
11
|
+
/** Every token this plugin takes, for `holocron doctor tokens`. */
|
|
12
|
+
const tokens = [resolveToken.token];
|
|
11
13
|
// src/capabilities/analytics.ts
|
|
12
14
|
var PostHogAnalytics = class {
|
|
13
15
|
client;
|
|
@@ -100,4 +102,4 @@ function createPlugin(options = {}) {
|
|
|
100
102
|
};
|
|
101
103
|
}
|
|
102
104
|
const AUTH_HINT = "create a personal API key at https://app.posthog.com/settings/user/api-keys (not the project API key — that is the client-side phc_* tracking token), then run: holocron auth set posthog <phx_KEY>";
|
|
103
|
-
export { AUTH_HINT, AuthError, PostHogAnalytics, analytics, createContext, createPlugin, createPostHogClient, resolveToken, verifyToken };
|
|
105
|
+
export { AUTH_HINT, AuthError, PostHogAnalytics, analytics, createContext, createPlugin, createPostHogClient, resolveToken, tokens, verifyToken };
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@theholocron/holocron-plugin-posthog",
|
|
3
|
-
"version": "5.0.0-alpha.
|
|
3
|
+
"version": "5.0.0-alpha.272",
|
|
4
4
|
"description": "Holocron plugin for PostHog. Implements the analytics capability — project provisioning and tracking token retrieval.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"analytics",
|
|
@@ -44,17 +44,17 @@
|
|
|
44
44
|
"tsx": "4.23.15",
|
|
45
45
|
"typescript": "^5.9.3",
|
|
46
46
|
"vitest": "^5.0.5",
|
|
47
|
-
"@theholocron/
|
|
47
|
+
"@theholocron/cli": "5.0.0-alpha.272",
|
|
48
48
|
"@theholocron/eslint-config": "^8.9.0-alpha.3",
|
|
49
49
|
"@theholocron/misc-utils": "^1.16.1-alpha.1",
|
|
50
|
-
"@theholocron/
|
|
51
|
-
"@theholocron/vitest-config": "^8.9.0-alpha.3",
|
|
50
|
+
"@theholocron/tsconfig": "^8.9.0-alpha.3",
|
|
52
51
|
"@theholocron/tsdown-config": "^8.9.0-alpha.3",
|
|
53
|
-
"@theholocron/
|
|
52
|
+
"@theholocron/vitest-config": "^8.9.0-alpha.3",
|
|
53
|
+
"@theholocron/http-client": "^1.58.0-alpha.2"
|
|
54
54
|
},
|
|
55
55
|
"peerDependencies": {
|
|
56
56
|
"@theholocron/misc-utils": "^1.16.0",
|
|
57
|
-
"@theholocron/cli": "5.0.0-alpha.
|
|
57
|
+
"@theholocron/cli": "5.0.0-alpha.272"
|
|
58
58
|
},
|
|
59
59
|
"engines": {
|
|
60
60
|
"node": ">=22"
|