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

Do not track playback until we send back more than 0 dom bytes #132

Merged
merged 7 commits into from
May 17, 2021
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Detect duplicate clarity instance
  • Loading branch information
Sarvesh Nagpal committed May 17, 2021
commit fa7cfcc7f7eb79d1628c25a491f7532816a820a4
2 changes: 1 addition & 1 deletion packages/clarity-js/src/global.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import * as clarity from "@src/clarity";
(function(): void {
if (typeof window !== "undefined") {
const w = window as any;
if (!w.clarity.q) { console.log("Error CL001: Multiple Clarity tags detected."); }
if (w.clarity && !w.clarity.q) { console.warn("Error CL001: Multiple Clarity tags detected."); }
const queue = w.clarity ? (w.clarity.q || []) : [];
w.clarity = function(method: string, ...args: any[]): void { return clarity[method](...args); }
while (queue.length > 0) { w.clarity(...queue.shift()); }
Expand Down