@shware/analytics 0.1.3 → 0.1.4
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 +8 -1
- package/dist/index.mjs +2 -2
- package/package.json +1 -1
package/dist/index.d.mts
CHANGED
|
@@ -192,5 +192,12 @@ declare const createVisitorSchema: z.ZodObject<{
|
|
|
192
192
|
device_id: string;
|
|
193
193
|
properties: Record<string, string | number | boolean | null>;
|
|
194
194
|
}>;
|
|
195
|
+
declare const updateVisitorSchema: z.ZodObject<{
|
|
196
|
+
properties: z.ZodEffects<z.ZodRecord<z.ZodString, z.ZodUnion<[z.ZodString, z.ZodNumber, z.ZodBoolean, z.ZodNull]>>, Record<string, string | number | boolean | null>, Record<string, string | number | boolean | null>>;
|
|
197
|
+
}, "strip", z.ZodTypeAny, {
|
|
198
|
+
properties: Record<string, string | number | boolean | null>;
|
|
199
|
+
}, {
|
|
200
|
+
properties: Record<string, string | number | boolean | null>;
|
|
201
|
+
}>;
|
|
195
202
|
|
|
196
|
-
export { TrackProperties, TrackTags, VisitorProperties, createTrackEventSchema, createVisitorSchema, getVisitor, setVisitor, setupAnalytics, track };
|
|
203
|
+
export { TrackProperties, TrackTags, VisitorProperties, createTrackEventSchema, createVisitorSchema, getVisitor, setVisitor, setupAnalytics, track, updateVisitorSchema };
|
package/dist/index.mjs
CHANGED
|
@@ -134,11 +134,11 @@ const createVisitorSchema = z.object({
|
|
|
134
134
|
z.union([z.string().max(512), z.number(), z.boolean(), z.null()])
|
|
135
135
|
).refine((data) => Object.keys(data).length <= 64)
|
|
136
136
|
});
|
|
137
|
-
z.object({
|
|
137
|
+
const updateVisitorSchema = z.object({
|
|
138
138
|
properties: z.record(
|
|
139
139
|
z.string().trim().min(1).max(128),
|
|
140
140
|
z.union([z.string().max(512), z.number(), z.boolean(), z.null()])
|
|
141
141
|
).refine((data) => Object.keys(data).length <= 64)
|
|
142
142
|
});
|
|
143
143
|
|
|
144
|
-
export { createTrackEventSchema, createVisitorSchema, getVisitor, setVisitor, setupAnalytics, track };
|
|
144
|
+
export { createTrackEventSchema, createVisitorSchema, getVisitor, setVisitor, setupAnalytics, track, updateVisitorSchema };
|