@c15t/scripts 2.1.0 → 2.2.0-canary-20260804162155

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.
Files changed (140) hide show
  1. package/AGENTS.md +62 -0
  2. package/README.md +32 -20
  3. package/dist/e2e-test-utils.cjs +51 -10
  4. package/dist/e2e-test-utils.js +37 -3
  5. package/dist/engine/compile.cjs +9 -5
  6. package/dist/engine/runtime.cjs +103 -17
  7. package/dist/engine/runtime.js +94 -12
  8. package/dist/registry.cjs +97 -12
  9. package/dist/registry.js +80 -0
  10. package/dist/resolve.cjs +9 -5
  11. package/dist/types.cjs +17 -13
  12. package/dist/vendors/_shared/attributes.cjs +13 -9
  13. package/dist/vendors/_shared/google-consent.cjs +14 -9
  14. package/dist/vendors/_shared/install-builders.cjs +12 -8
  15. package/dist/vendors/_shared/script-url.cjs +16 -12
  16. package/dist/vendors/ads-and-pixels/linkedin-insights.cjs +9 -5
  17. package/dist/vendors/ads-and-pixels/meta-pixel.cjs +13 -9
  18. package/dist/vendors/ads-and-pixels/microsoft-uet.cjs +11 -7
  19. package/dist/vendors/ads-and-pixels/reddit-pixel.cjs +9 -5
  20. package/dist/vendors/ads-and-pixels/snapchat-pixel.cjs +11 -7
  21. package/dist/vendors/ads-and-pixels/tiktok-pixel.cjs +9 -5
  22. package/dist/vendors/ads-and-pixels/x-pixel.cjs +9 -5
  23. package/dist/vendors/analytics/adobe-analytics.cjs +90 -0
  24. package/dist/vendors/analytics/adobe-analytics.js +49 -0
  25. package/dist/vendors/analytics/ahrefs-analytics.cjs +11 -7
  26. package/dist/vendors/analytics/amplitude.cjs +193 -0
  27. package/dist/vendors/analytics/amplitude.js +134 -0
  28. package/dist/vendors/analytics/clearbit.cjs +69 -0
  29. package/dist/vendors/analytics/clearbit.js +28 -0
  30. package/dist/vendors/analytics/cloudflare-web-analytics.cjs +11 -7
  31. package/dist/vendors/analytics/databuddy.cjs +11 -7
  32. package/dist/vendors/analytics/fathom-analytics.cjs +11 -7
  33. package/dist/vendors/analytics/google-tag.cjs +11 -7
  34. package/dist/vendors/analytics/heap.cjs +181 -0
  35. package/dist/vendors/analytics/heap.js +134 -0
  36. package/dist/vendors/analytics/hightouch.cjs +153 -0
  37. package/dist/vendors/analytics/hightouch.js +109 -0
  38. package/dist/vendors/analytics/hotjar.cjs +11 -7
  39. package/dist/vendors/analytics/logrocket.cjs +99 -0
  40. package/dist/vendors/analytics/logrocket.js +58 -0
  41. package/dist/vendors/analytics/matomo-analytics.cjs +9 -5
  42. package/dist/vendors/analytics/microsoft-clarity.cjs +75 -47
  43. package/dist/vendors/analytics/microsoft-clarity.js +64 -40
  44. package/dist/vendors/analytics/mixpanel-analytics.cjs +31 -16
  45. package/dist/vendors/analytics/mixpanel-analytics.js +22 -11
  46. package/dist/vendors/analytics/pirsch.cjs +108 -0
  47. package/dist/vendors/analytics/pirsch.js +67 -0
  48. package/dist/vendors/analytics/plausible-analytics.cjs +9 -5
  49. package/dist/vendors/analytics/posthog.cjs +63 -27
  50. package/dist/vendors/analytics/posthog.js +52 -20
  51. package/dist/vendors/analytics/promptwatch.cjs +11 -7
  52. package/dist/vendors/analytics/rudderstack.cjs +227 -0
  53. package/dist/vendors/analytics/rudderstack.js +183 -0
  54. package/dist/vendors/analytics/rybbit-analytics.cjs +9 -5
  55. package/dist/vendors/analytics/segment.cjs +9 -5
  56. package/dist/vendors/analytics/umami-analytics.cjs +9 -5
  57. package/dist/vendors/analytics/vercel-analytics.cjs +11 -7
  58. package/dist/vendors/functional/crisp.cjs +9 -5
  59. package/dist/vendors/functional/intercom.cjs +11 -7
  60. package/dist/vendors/tag-managers/google-tag-manager.cjs +11 -7
  61. package/dist-types/registry.d.ts +313 -241
  62. package/dist-types/types.d.ts +46 -4
  63. package/dist-types/vendors/ads-and-pixels/linkedin-insights.d.ts +18 -18
  64. package/dist-types/vendors/ads-and-pixels/meta-pixel.d.ts +21 -21
  65. package/dist-types/vendors/ads-and-pixels/microsoft-uet.d.ts +32 -32
  66. package/dist-types/vendors/ads-and-pixels/reddit-pixel.d.ts +19 -19
  67. package/dist-types/vendors/ads-and-pixels/snapchat-pixel.d.ts +16 -16
  68. package/dist-types/vendors/ads-and-pixels/tiktok-pixel.d.ts +28 -28
  69. package/dist-types/vendors/ads-and-pixels/x-pixel.d.ts +13 -13
  70. package/dist-types/vendors/analytics/adobe-analytics.d.ts +75 -0
  71. package/dist-types/vendors/analytics/ahrefs-analytics.d.ts +7 -7
  72. package/dist-types/vendors/analytics/amplitude.d.ts +234 -0
  73. package/dist-types/vendors/analytics/clearbit.d.ts +60 -0
  74. package/dist-types/vendors/analytics/cloudflare-web-analytics.d.ts +7 -7
  75. package/dist-types/vendors/analytics/databuddy.d.ts +25 -25
  76. package/dist-types/vendors/analytics/fathom-analytics.d.ts +11 -11
  77. package/dist-types/vendors/analytics/google-tag.d.ts +17 -17
  78. package/dist-types/vendors/analytics/heap.d.ts +316 -0
  79. package/dist-types/vendors/analytics/hightouch.d.ts +285 -0
  80. package/dist-types/vendors/analytics/hotjar.d.ts +14 -14
  81. package/dist-types/vendors/analytics/logrocket.d.ts +101 -0
  82. package/dist-types/vendors/analytics/microsoft-clarity.d.ts +42 -30
  83. package/dist-types/vendors/analytics/mixpanel-analytics.d.ts +40 -28
  84. package/dist-types/vendors/analytics/pirsch.d.ts +96 -0
  85. package/dist-types/vendors/analytics/plausible-analytics.d.ts +13 -13
  86. package/dist-types/vendors/analytics/posthog.d.ts +63 -45
  87. package/dist-types/vendors/analytics/promptwatch.d.ts +7 -7
  88. package/dist-types/vendors/analytics/rudderstack.d.ts +330 -0
  89. package/dist-types/vendors/analytics/rybbit-analytics.d.ts +18 -18
  90. package/dist-types/vendors/analytics/segment.d.ts +13 -13
  91. package/dist-types/vendors/analytics/umami-analytics.d.ts +12 -12
  92. package/dist-types/vendors/analytics/vercel-analytics.d.ts +16 -16
  93. package/dist-types/vendors/functional/crisp.d.ts +11 -11
  94. package/dist-types/vendors/functional/intercom.d.ts +16 -16
  95. package/dist-types/vendors/tag-managers/google-tag-manager.d.ts +18 -18
  96. package/docs/README.md +62 -0
  97. package/docs/frameworks/javascript/script-loader.md +356 -0
  98. package/docs/frameworks/next/script-loader.md +501 -0
  99. package/docs/frameworks/react/script-loader.md +555 -0
  100. package/docs/integrations/adobe-analytics.md +160 -0
  101. package/docs/integrations/ahrefs-analytics.md +157 -0
  102. package/docs/integrations/amplitude.md +230 -0
  103. package/docs/integrations/building-integrations.md +239 -0
  104. package/docs/integrations/clearbit.md +130 -0
  105. package/docs/integrations/cloudflare-web-analytics.md +126 -0
  106. package/docs/integrations/crisp.md +140 -0
  107. package/docs/integrations/databuddy.md +205 -0
  108. package/docs/integrations/fathom-analytics.md +150 -0
  109. package/docs/integrations/google-maps.md +263 -0
  110. package/docs/integrations/google-tag-manager.md +154 -0
  111. package/docs/integrations/google-tag.md +134 -0
  112. package/docs/integrations/heap.md +219 -0
  113. package/docs/integrations/hightouch.md +199 -0
  114. package/docs/integrations/hotjar.md +143 -0
  115. package/docs/integrations/intercom.md +144 -0
  116. package/docs/integrations/linkedin-insights.md +161 -0
  117. package/docs/integrations/logrocket.md +175 -0
  118. package/docs/integrations/matomo-analytics.md +171 -0
  119. package/docs/integrations/meta-pixel.md +412 -0
  120. package/docs/integrations/microsoft-clarity.md +173 -0
  121. package/docs/integrations/microsoft-uet.md +156 -0
  122. package/docs/integrations/mixpanel-analytics.md +130 -0
  123. package/docs/integrations/overview.md +149 -0
  124. package/docs/integrations/pirsch.md +142 -0
  125. package/docs/integrations/plausible-analytics.md +154 -0
  126. package/docs/integrations/posthog.md +258 -0
  127. package/docs/integrations/promptwatch.md +121 -0
  128. package/docs/integrations/reddit-pixel.md +241 -0
  129. package/docs/integrations/rudderstack.md +271 -0
  130. package/docs/integrations/rybbit-analytics.md +143 -0
  131. package/docs/integrations/segment.md +146 -0
  132. package/docs/integrations/snapchat-pixel.md +163 -0
  133. package/docs/integrations/tiktok-pixel.md +123 -0
  134. package/docs/integrations/umami-analytics.md +148 -0
  135. package/docs/integrations/vercel-analytics.md +141 -0
  136. package/docs/integrations/x-pixel.md +157 -0
  137. package/docs/integrations/youtube.md +193 -0
  138. package/docs/shared/react/guides/script-loader.md +311 -0
  139. package/package.json +61 -7
  140. package/readme.json +8 -4
@@ -0,0 +1,330 @@
1
+ import type { Script } from 'c15t';
2
+ export declare const RUDDERSTACK_QUEUE_METHODS: readonly ['setDefaultInstanceKey', 'load', 'ready', 'page', 'track', 'identify', 'alias', 'group', 'reset', 'setAnonymousId', 'startSession', 'endSession', 'consent', 'addCustomIntegration'];
3
+ type JsonPrimitive = string | number | boolean | null;
4
+ type JsonValue = JsonPrimitive | JsonObject | JsonValue[];
5
+ /**
6
+ * JSON-serializable object passed to RudderStack's `load()` API.
7
+ */
8
+ export interface JsonObject {
9
+ [key: string]: JsonValue;
10
+ }
11
+ /**
12
+ * RudderStack JavaScript SDK `load()` options.
13
+ *
14
+ * The options are interpolated into a script manifest and passed as the third
15
+ * `rudderanalytics.load(writeKey, dataPlaneUrl, options)` argument. Keep values
16
+ * JSON-serializable: plain objects, arrays, strings, numbers, booleans, and
17
+ * `null`. Functions, class instances, Dates, Maps, Sets, and symbols are not
18
+ * supported.
19
+ */
20
+ export type RudderStackLoadOptions = JsonObject;
21
+ /**
22
+ * Public RudderStack JavaScript SDK API exposed on `window.rudderanalytics`.
23
+ *
24
+ * The official v3 CDN snippet starts as an array-backed queue and the loaded
25
+ * SDK replaces it with an initialized runtime object. Use this interface for
26
+ * calls made after consent has allowed the SDK to load.
27
+ *
28
+ * @example
29
+ * ```ts
30
+ * window.rudderanalytics?.track('Signup Completed', { plan: 'pro' });
31
+ * ```
32
+ */
33
+ export interface RudderStackApi {
34
+ /**
35
+ * Sets the default instance key for multi-instance setups.
36
+ *
37
+ * @param key - Instance key to use for subsequent calls.
38
+ * @returns The RudderStack runtime or a promise-like value from the SDK.
39
+ */
40
+ setDefaultInstanceKey: (key: string) => unknown;
41
+ /**
42
+ * Loads and initializes the RudderStack JavaScript SDK.
43
+ *
44
+ * @param writeKey - Source write key from RudderStack.
45
+ * @param dataPlaneUrl - HTTPS data plane URL for the source.
46
+ * @param options - Optional JSON-serializable load options.
47
+ * @returns The RudderStack runtime or a promise-like value from the SDK.
48
+ */
49
+ load: (writeKey: string, dataPlaneUrl: string, options?: RudderStackLoadOptions) => unknown;
50
+ /**
51
+ * Registers a callback that fires when the SDK is ready.
52
+ *
53
+ * @param callback - Function to run once the SDK is ready.
54
+ * @returns The RudderStack runtime or a promise-like value from the SDK.
55
+ */
56
+ ready: (callback: () => void) => unknown;
57
+ /**
58
+ * Tracks a page view with optional category, name, properties, and options.
59
+ *
60
+ * @param category - Optional page category.
61
+ * @param name - Optional page name.
62
+ * @param properties - Optional page metadata payload.
63
+ * @param options - Optional event context or integrations options.
64
+ * @param callback - Optional callback after processing.
65
+ * @returns The RudderStack runtime or a promise-like value from the SDK.
66
+ */
67
+ page: (category?: string, name?: string, properties?: Record<string, unknown>, options?: Record<string, unknown>, callback?: () => void) => unknown;
68
+ /**
69
+ * Tracks a named event.
70
+ *
71
+ * @param event - Event name to record.
72
+ * @param properties - Optional event properties payload.
73
+ * @param options - Optional event context or integrations options.
74
+ * @param callback - Optional callback after processing.
75
+ * @returns The RudderStack runtime or a promise-like value from the SDK.
76
+ */
77
+ track: (event: string, properties?: Record<string, unknown>, options?: Record<string, unknown>, callback?: () => void) => unknown;
78
+ /**
79
+ * Identifies a user and associates traits with that identity.
80
+ *
81
+ * @param userId - Stable user identifier.
82
+ * @param traits - Optional trait map associated with the user.
83
+ * @param options - Optional event context or integrations options.
84
+ * @param callback - Optional callback after processing.
85
+ * @returns The RudderStack runtime or a promise-like value from the SDK.
86
+ */
87
+ identify: (userId: string, traits?: Record<string, unknown>, options?: Record<string, unknown>, callback?: () => void) => unknown;
88
+ /**
89
+ * Aliases one user identifier to another.
90
+ *
91
+ * @param userId - New canonical user identifier.
92
+ * @param previousId - Optional previous identifier.
93
+ * @param options - Optional event context or integrations options.
94
+ * @param callback - Optional callback after processing.
95
+ * @returns The RudderStack runtime or a promise-like value from the SDK.
96
+ */
97
+ alias: (userId: string, previousId?: string, options?: Record<string, unknown>, callback?: () => void) => unknown;
98
+ /**
99
+ * Associates the current user with a group or account.
100
+ *
101
+ * @param groupId - Group or account identifier.
102
+ * @param traits - Optional group trait map.
103
+ * @param options - Optional event context or integrations options.
104
+ * @param callback - Optional callback after processing.
105
+ * @returns The RudderStack runtime or a promise-like value from the SDK.
106
+ */
107
+ group: (groupId: string, traits?: Record<string, unknown>, options?: Record<string, unknown>, callback?: () => void) => unknown;
108
+ /**
109
+ * Clears the current user identity state.
110
+ *
111
+ * @returns The RudderStack runtime or a promise-like value from the SDK.
112
+ */
113
+ reset: () => unknown;
114
+ /**
115
+ * Sets the anonymous ID used for subsequent events.
116
+ *
117
+ * @param anonymousId - Anonymous identifier to assign.
118
+ * @returns The RudderStack runtime or a promise-like value from the SDK.
119
+ */
120
+ setAnonymousId: (anonymousId: string) => unknown;
121
+ /**
122
+ * Starts a session with an optional session identifier.
123
+ *
124
+ * @param sessionId - Optional session identifier.
125
+ * @returns The RudderStack runtime or a promise-like value from the SDK.
126
+ */
127
+ startSession: (sessionId?: string) => unknown;
128
+ /**
129
+ * Ends the current session.
130
+ *
131
+ * @returns The RudderStack runtime or a promise-like value from the SDK.
132
+ */
133
+ endSession: () => unknown;
134
+ /**
135
+ * Transitions the SDK from pre-consent to post-consent behavior.
136
+ *
137
+ * @param consentOptions - Vendor-supported consent options.
138
+ * @returns The RudderStack runtime or a promise-like value from the SDK.
139
+ *
140
+ * @remarks
141
+ * This API is for RudderStack's consent-management flow. In the default
142
+ * (blocked-load) mode it is not a c15t revocation hook; c15t unloads the
143
+ * SDK when measurement consent is revoked. In the opt-in pre-consent mode
144
+ * (`consentManagement` option) c15t calls it with the mapped consent IDs on
145
+ * every consent decision and change.
146
+ */
147
+ consent: (consentOptions?: Record<string, unknown>) => unknown;
148
+ /**
149
+ * Registers a custom device-mode integration. RudderStack only accepts
150
+ * registrations made before `load()` completes, which is why this is part
151
+ * of the pre-load queue.
152
+ *
153
+ * @param name - Integration name.
154
+ * @param integration - Integration implementation object.
155
+ * @returns The RudderStack runtime or a promise-like value from the SDK.
156
+ */
157
+ addCustomIntegration: (name: string, integration: unknown) => unknown;
158
+ }
159
+ declare global {
160
+ interface Window {
161
+ rudderanalytics?: RudderStackApi;
162
+ rudderAnalyticsBuildType?: string;
163
+ RudderSnippetVersion?: string;
164
+ }
165
+ }
166
+ /**
167
+ * RudderStack vendor manifest.
168
+ *
169
+ * Creates RudderStack's v3 `window.rudderanalytics` queue, marks the snippet as
170
+ * seeded, queues the required `load()` call and optional `page()` call, then
171
+ * lets c15t own the script element.
172
+ */
173
+ export declare const rudderstackManifest: {
174
+ readonly kind: "c15t.vendor-manifest";
175
+ readonly schemaVersion: 1;
176
+ readonly vendor: 'rudderstack';
177
+ readonly category: 'measurement';
178
+ readonly bootstrap: [{
179
+ readonly type: 'setGlobal';
180
+ readonly name: 'rudderanalytics';
181
+ readonly value: readonly [];
182
+ readonly ifUndefined: true;
183
+ }, {
184
+ readonly type: 'setGlobal';
185
+ readonly name: 'RudderSnippetVersion';
186
+ readonly value: '3.0.32';
187
+ }, {
188
+ readonly type: 'setGlobal';
189
+ readonly name: 'rudderAnalyticsBuildType';
190
+ readonly value: 'modern';
191
+ }, {
192
+ readonly type: 'setGlobalPath';
193
+ readonly path: ["rudderanalytics", "snippetExecuted"];
194
+ readonly value: true;
195
+ }, {
196
+ readonly type: 'defineQueueMethods';
197
+ readonly target: 'rudderanalytics';
198
+ readonly methods: ["setDefaultInstanceKey", "load", "ready", "page", "track", "identify", "alias", "group", "reset", "setAnonymousId", "startSession", "endSession", "consent", "addCustomIntegration"];
199
+ }];
200
+ readonly install: [{
201
+ readonly type: 'callGlobal';
202
+ readonly global: 'rudderanalytics';
203
+ readonly method: 'load';
204
+ readonly args: ["{{writeKey}}", "{{dataPlaneUrl}}", "{{loadOptions}}"];
205
+ }, {
206
+ readonly type: 'callGlobal';
207
+ readonly global: 'rudderanalytics';
208
+ readonly method: 'page';
209
+ }, {
210
+ readonly type: 'loadScript';
211
+ readonly src: '{{scriptUrl}}';
212
+ readonly async: true;
213
+ readonly attributes: {
214
+ readonly 'data-loader': 'RS_JS_SDK';
215
+ readonly 'data-rsa-write-key': '{{writeKey}}';
216
+ };
217
+ }];
218
+ };
219
+ /**
220
+ * c15t consent categories accepted by the RudderStack consent mapping.
221
+ */
222
+ export type RudderStackConsentCategory = 'necessary' | 'functionality' | 'experience' | 'measurement' | 'marketing';
223
+ /**
224
+ * Opt-in pre-consent mode configuration.
225
+ *
226
+ * When provided, the SDK loads immediately for every visitor in RudderStack's
227
+ * pre-consent state (no persistent storage, events buffered in memory) and
228
+ * c15t signals consent decisions through `rudderanalytics.consent()` with the
229
+ * mapped consent IDs. This preserves pre-consent event attribution for users
230
+ * who go on to consent, at the cost of running vendor code before consent.
231
+ *
232
+ * Every destination in your RudderStack workspace must carry the consent IDs
233
+ * used here — c15t cannot verify that configuration from the browser, which is
234
+ * why this mode is opt-in and blocking the load stays the default.
235
+ */
236
+ export interface RudderStackConsentManagementOptions {
237
+ /**
238
+ * c15t consent category → RudderStack consent IDs.
239
+ *
240
+ * IDs come from your RudderStack destination consent settings. Categories
241
+ * granted in c15t contribute their IDs to `allowedConsentIds`; everything
242
+ * else lands in `deniedConsentIds`.
243
+ *
244
+ * @example
245
+ * ```ts
246
+ * {
247
+ * measurement: ['product-analytics'],
248
+ * marketing: ['ad-destinations'],
249
+ * }
250
+ * ```
251
+ */
252
+ mapping: Partial<Record<RudderStackConsentCategory, string[]>>;
253
+ }
254
+ export interface RudderStackOptions {
255
+ /**
256
+ * RudderStack source write key.
257
+ */
258
+ writeKey: string;
259
+ /**
260
+ * RudderStack HTTPS data plane URL.
261
+ */
262
+ dataPlaneUrl: string;
263
+ /**
264
+ * Opt into RudderStack's pre-consent mode with c15t as the consent
265
+ * provider instead of blocking the SDK load until consent.
266
+ *
267
+ * Defaults to `undefined`, which keeps the safe default: the SDK does not
268
+ * load until `measurement` consent is granted. See
269
+ * {@link RudderStackConsentManagementOptions} for the tradeoffs.
270
+ */
271
+ consentManagement?: RudderStackConsentManagementOptions;
272
+ /**
273
+ * Optional JSON-serializable RudderStack `load()` options.
274
+ *
275
+ * Values must be JSON-serializable because c15t resolves the manifest into
276
+ * script lifecycle callbacks. Do not pass functions, Dates, Maps, Sets,
277
+ * class instances, symbols, or other non-JSON values.
278
+ */
279
+ loadOptions?: RudderStackLoadOptions;
280
+ /**
281
+ * Queue the initial `rudderanalytics.page()` call during setup.
282
+ *
283
+ * @default true
284
+ */
285
+ trackPageView?: boolean;
286
+ /**
287
+ * Optional full loader URL override.
288
+ *
289
+ * @default 'https://cdn.rudderlabs.com/v3/modern/rsa.min.js'
290
+ */
291
+ scriptUrl?: string;
292
+ }
293
+ /**
294
+ * Creates a RudderStack JavaScript SDK script.
295
+ *
296
+ * @see https://www.rudderstack.com/docs/sources/event-streams/sdks/rudderstack-javascript-sdk/quickstart/
297
+ *
298
+ * @param options - The options for the RudderStack script.
299
+ * @returns The RudderStack script configuration.
300
+ * @throws {Error} When `writeKey` is missing or only whitespace.
301
+ * @throws {Error} When `dataPlaneUrl` is missing, invalid, or not HTTPS.
302
+ *
303
+ * @remarks
304
+ * RudderStack collects customer behavior and sends it to destinations through
305
+ * your configured data plane. By default c15t gates the browser SDK on
306
+ * `measurement` consent and unloads it when that consent is revoked.
307
+ * `loadOptions` is passed directly as the third `load()` argument and must be
308
+ * JSON-serializable.
309
+ *
310
+ * Pass `consentManagement` to opt into RudderStack's pre-consent mode instead:
311
+ * the SDK loads immediately with no persistent storage and buffered events,
312
+ * and c15t signals every consent decision through `rudderanalytics.consent()`
313
+ * with your mapped consent IDs — preserving pre-consent event attribution for
314
+ * users who consent. Requires consent IDs on every RudderStack destination.
315
+ *
316
+ * @example
317
+ * ```ts
318
+ * import { rudderstack } from '@c15t/scripts/rudderstack';
319
+ *
320
+ * rudderstack({
321
+ * writeKey: 'WRITE_KEY',
322
+ * dataPlaneUrl: 'https://example.dataplane.rudderstack.com',
323
+ * loadOptions: {
324
+ * useBeacon: true,
325
+ * },
326
+ * });
327
+ * ```
328
+ */
329
+ export declare function rudderstack({ writeKey, dataPlaneUrl, consentManagement, loadOptions, trackPageView, scriptUrl, }: RudderStackOptions): Script;
330
+ export {};
@@ -16,29 +16,29 @@ declare global {
16
16
  * Rybbit reads its configuration from script data attributes at load time.
17
17
  */
18
18
  export declare const rybbitAnalyticsManifest: {
19
- readonly vendor: "rybbit-analytics";
20
- readonly category: "measurement";
19
+ readonly kind: "c15t.vendor-manifest";
20
+ readonly schemaVersion: 1;
21
+ readonly vendor: 'rybbit-analytics';
22
+ readonly category: 'measurement';
21
23
  readonly install: [{
22
- readonly type: "loadScript";
23
- readonly src: "{{scriptUrl}}";
24
+ readonly type: 'loadScript';
25
+ readonly src: '{{scriptUrl}}';
24
26
  readonly defer: true;
25
27
  readonly attributes: {
26
- readonly 'data-site-id': "{{siteId}}";
27
- readonly 'data-auto-track-pageview': "{{autoTrackPageview}}";
28
- readonly 'data-track-spa': "{{trackSpa}}";
29
- readonly 'data-track-query': "{{trackQuery}}";
30
- readonly 'data-track-outbound': "{{trackOutbound}}";
31
- readonly 'data-track-errors': "{{trackErrors}}";
32
- readonly 'data-session-replay': "{{sessionReplay}}";
33
- readonly 'data-web-vitals': "{{webVitals}}";
34
- readonly 'data-skip-patterns': "{{skipPatterns}}";
35
- readonly 'data-mask-patterns': "{{maskPatterns}}";
36
- readonly 'data-debounce': "{{debounce}}";
37
- readonly 'data-api-key': "{{apiKey}}";
28
+ readonly 'data-site-id': '{{siteId}}';
29
+ readonly 'data-auto-track-pageview': '{{autoTrackPageview}}';
30
+ readonly 'data-track-spa': '{{trackSpa}}';
31
+ readonly 'data-track-query': '{{trackQuery}}';
32
+ readonly 'data-track-outbound': '{{trackOutbound}}';
33
+ readonly 'data-track-errors': '{{trackErrors}}';
34
+ readonly 'data-session-replay': '{{sessionReplay}}';
35
+ readonly 'data-web-vitals': '{{webVitals}}';
36
+ readonly 'data-skip-patterns': '{{skipPatterns}}';
37
+ readonly 'data-mask-patterns': '{{maskPatterns}}';
38
+ readonly 'data-debounce': '{{debounce}}';
39
+ readonly 'data-api-key': '{{apiKey}}';
38
40
  };
39
41
  }];
40
- readonly kind: "c15t.vendor-manifest";
41
- readonly schemaVersion: 1;
42
42
  };
43
43
  export interface RybbitAnalyticsOptions {
44
44
  /** Your Rybbit site ID. */
@@ -117,29 +117,29 @@ declare global {
117
117
  * the initial `page()` call before the bundle loads.
118
118
  */
119
119
  export declare const segmentManifest: {
120
- readonly vendor: "segment";
121
- readonly category: "measurement";
120
+ readonly kind: "c15t.vendor-manifest";
121
+ readonly schemaVersion: 1;
122
+ readonly vendor: 'segment';
123
+ readonly category: 'measurement';
122
124
  readonly bootstrap: [{
123
- readonly type: "setGlobal";
124
- readonly name: "analytics";
125
+ readonly type: 'setGlobal';
126
+ readonly name: 'analytics';
125
127
  readonly value: readonly [];
126
128
  readonly ifUndefined: true;
127
129
  }, {
128
- readonly type: "defineQueueMethods";
129
- readonly target: "analytics";
130
+ readonly type: 'defineQueueMethods';
131
+ readonly target: 'analytics';
130
132
  readonly methods: ["track", "page", "identify", "group", "alias", "reset"];
131
133
  }];
132
134
  readonly install: [{
133
- readonly type: "callGlobal";
134
- readonly global: "analytics";
135
- readonly method: "page";
135
+ readonly type: 'callGlobal';
136
+ readonly global: 'analytics';
137
+ readonly method: 'page';
136
138
  }, {
137
- readonly type: "loadScript";
138
- readonly src: "{{scriptUrl}}";
139
+ readonly type: 'loadScript';
140
+ readonly src: '{{scriptUrl}}';
139
141
  readonly async: true;
140
142
  }];
141
- readonly kind: "c15t.vendor-manifest";
142
- readonly schemaVersion: 1;
143
143
  };
144
144
  export interface SegmentOptions {
145
145
  /** Your Segment write key. */
@@ -18,23 +18,23 @@ declare global {
18
18
  * `measurement` and unloaded when consent is revoked.
19
19
  */
20
20
  export declare const umamiAnalyticsManifest: {
21
- readonly vendor: "umami-analytics";
22
- readonly category: "measurement";
21
+ readonly kind: "c15t.vendor-manifest";
22
+ readonly schemaVersion: 1;
23
+ readonly vendor: 'umami-analytics';
24
+ readonly category: 'measurement';
23
25
  readonly install: [{
24
- readonly type: "loadScript";
25
- readonly src: "{{scriptUrl}}";
26
+ readonly type: 'loadScript';
27
+ readonly src: '{{scriptUrl}}';
26
28
  readonly defer: true;
27
29
  readonly attributes: {
28
- readonly 'data-website-id': "{{websiteId}}";
29
- readonly 'data-host-url': "{{hostUrl}}";
30
- readonly 'data-auto-track': "{{autoTrackAttribute}}";
31
- readonly 'data-domains': "{{domains}}";
32
- readonly 'data-tag': "{{tag}}";
33
- readonly 'data-before-send': "{{beforeSend}}";
30
+ readonly 'data-website-id': '{{websiteId}}';
31
+ readonly 'data-host-url': '{{hostUrl}}';
32
+ readonly 'data-auto-track': '{{autoTrackAttribute}}';
33
+ readonly 'data-domains': '{{domains}}';
34
+ readonly 'data-tag': '{{tag}}';
35
+ readonly 'data-before-send': '{{beforeSend}}';
34
36
  };
35
37
  }];
36
- readonly kind: "c15t.vendor-manifest";
37
- readonly schemaVersion: 1;
38
38
  };
39
39
  export interface UmamiAnalyticsOptions {
40
40
  /**
@@ -13,35 +13,35 @@ declare global {
13
13
  * Seeds Vercel's event queue before loading the tracker bundle.
14
14
  */
15
15
  export declare const vercelAnalyticsManifest: {
16
- readonly vendor: "vercel-analytics";
17
- readonly category: "measurement";
16
+ readonly kind: "c15t.vendor-manifest";
17
+ readonly schemaVersion: 1;
18
+ readonly vendor: 'vercel-analytics';
19
+ readonly category: 'measurement';
18
20
  readonly bootstrap: [{
19
- readonly type: "setGlobal";
20
- readonly name: "vaq";
21
+ readonly type: 'setGlobal';
22
+ readonly name: 'vaq';
21
23
  readonly value: readonly [];
22
24
  readonly ifUndefined: true;
23
25
  }, {
24
- readonly type: "defineStubFunction";
25
- readonly name: "va";
26
+ readonly type: 'defineStubFunction';
27
+ readonly name: 'va';
26
28
  readonly queue: {
27
- readonly global: "vaq";
29
+ readonly global: 'vaq';
28
30
  };
29
- readonly queueFormat: "array";
31
+ readonly queueFormat: 'array';
30
32
  readonly ifUndefined: true;
31
33
  }];
32
34
  readonly install: [{
33
- readonly type: "loadScript";
34
- readonly src: "{{scriptUrl}}";
35
+ readonly type: 'loadScript';
36
+ readonly src: '{{scriptUrl}}';
35
37
  readonly defer: true;
36
38
  readonly attributes: {
37
- readonly 'data-sdkn': "c15t";
38
- readonly 'data-dsn': "{{dsn}}";
39
- readonly 'data-disable-auto-track': "{{disableAutoTrackAttribute}}";
40
- readonly 'data-endpoint': "{{endpoint}}";
39
+ readonly 'data-sdkn': 'c15t';
40
+ readonly 'data-dsn': '{{dsn}}';
41
+ readonly 'data-disable-auto-track': '{{disableAutoTrackAttribute}}';
42
+ readonly 'data-endpoint': '{{endpoint}}';
41
43
  };
42
44
  }];
43
- readonly kind: "c15t.vendor-manifest";
44
- readonly schemaVersion: 1;
45
45
  };
46
46
  export interface VercelAnalyticsOptions {
47
47
  /** Project DSN for self-hosted or non-Vercel deployments. */
@@ -19,25 +19,25 @@ declare global {
19
19
  * Optional runtime globals are added when provided by the helper options.
20
20
  */
21
21
  export declare const crispManifest: {
22
- readonly vendor: "crisp";
23
- readonly category: "functionality";
22
+ readonly kind: "c15t.vendor-manifest";
23
+ readonly schemaVersion: 1;
24
+ readonly vendor: 'crisp';
25
+ readonly category: 'functionality';
24
26
  readonly install: [{
25
- readonly type: "setGlobal";
26
- readonly name: "$crisp";
27
+ readonly type: 'setGlobal';
28
+ readonly name: '$crisp';
27
29
  readonly value: readonly [];
28
30
  readonly ifUndefined: false;
29
31
  }, {
30
- readonly type: "setGlobal";
31
- readonly name: "CRISP_WEBSITE_ID";
32
- readonly value: "{{websiteId}}";
32
+ readonly type: 'setGlobal';
33
+ readonly name: 'CRISP_WEBSITE_ID';
34
+ readonly value: '{{websiteId}}';
33
35
  readonly ifUndefined: false;
34
36
  }, {
35
- readonly type: "loadScript";
36
- readonly src: "{{scriptSrc}}";
37
+ readonly type: 'loadScript';
38
+ readonly src: '{{scriptSrc}}';
37
39
  readonly async: true;
38
40
  }];
39
- readonly kind: "c15t.vendor-manifest";
40
- readonly schemaVersion: 1;
41
41
  };
42
42
  export interface CrispOptions {
43
43
  /** Your Crisp website ID. */
@@ -1,8 +1,8 @@
1
1
  import type { Script } from 'c15t';
2
2
  export declare const INTERCOM_API_BASES: {
3
- readonly us: "https://api-iam.intercom.io";
4
- readonly eu: "https://api-iam.eu.intercom.io";
5
- readonly au: "https://api-iam.au.intercom.io";
3
+ readonly us: 'https://api-iam.intercom.io';
4
+ readonly eu: 'https://api-iam.eu.intercom.io';
5
+ readonly au: 'https://api-iam.au.intercom.io';
6
6
  };
7
7
  export type IntercomApiBase = (typeof INTERCOM_API_BASES)[keyof typeof INTERCOM_API_BASES] | (string & {});
8
8
  export type IntercomThemeMode = 'light' | 'dark' | 'system';
@@ -72,28 +72,28 @@ declare global {
72
72
  * the messenger widget bundle.
73
73
  */
74
74
  export declare const intercomManifest: {
75
- readonly vendor: "intercom";
76
- readonly category: "functionality";
75
+ readonly kind: "c15t.vendor-manifest";
76
+ readonly schemaVersion: 1;
77
+ readonly vendor: 'intercom';
78
+ readonly category: 'functionality';
77
79
  readonly install: [{
78
- readonly type: "defineStubFunction";
79
- readonly name: "Intercom";
80
+ readonly type: 'defineStubFunction';
81
+ readonly name: 'Intercom';
80
82
  readonly queue: {
81
- readonly property: "q";
83
+ readonly property: 'q';
82
84
  };
83
- readonly queueFormat: "array";
85
+ readonly queueFormat: 'array';
84
86
  readonly ifUndefined: true;
85
87
  }, {
86
- readonly type: "setGlobal";
87
- readonly name: "intercomSettings";
88
- readonly value: "{{settings}}";
88
+ readonly type: 'setGlobal';
89
+ readonly name: 'intercomSettings';
90
+ readonly value: '{{settings}}';
89
91
  readonly ifUndefined: false;
90
92
  }, {
91
- readonly type: "loadScript";
92
- readonly src: "{{scriptSrc}}";
93
+ readonly type: 'loadScript';
94
+ readonly src: '{{scriptSrc}}';
93
95
  readonly async: true;
94
96
  }];
95
- readonly kind: "c15t.vendor-manifest";
96
- readonly schemaVersion: 1;
97
97
  };
98
98
  export interface IntercomOptions {
99
99
  /**