feat(telemetry): add plugin_loaded event for entry tracking
This commit is contained in:
+4
-1
@@ -40,10 +40,13 @@ const OhMyOpenCodePlugin: Plugin = async (ctx) => {
|
|||||||
const pluginConfig = loadPluginConfig(ctx.directory, ctx)
|
const pluginConfig = loadPluginConfig(ctx.directory, ctx)
|
||||||
|
|
||||||
const posthog = createPluginPostHog()
|
const posthog = createPluginPostHog()
|
||||||
|
const distinctId = getPostHogDistinctId()
|
||||||
|
posthog.trackActive(distinctId, "plugin_loaded")
|
||||||
posthog.capture({
|
posthog.capture({
|
||||||
distinctId: getPostHogDistinctId(),
|
distinctId,
|
||||||
event: "plugin_loaded",
|
event: "plugin_loaded",
|
||||||
properties: {
|
properties: {
|
||||||
|
entry_point: "plugin",
|
||||||
has_openclaw: !!pluginConfig.openclaw,
|
has_openclaw: !!pluginConfig.openclaw,
|
||||||
tmux_enabled: isTmuxIntegrationEnabled(pluginConfig),
|
tmux_enabled: isTmuxIntegrationEnabled(pluginConfig),
|
||||||
},
|
},
|
||||||
|
|||||||
Reference in New Issue
Block a user