mirror of
https://github.com/appwrite/console.git
synced 2026-06-06 19:27:48 +00:00
Merge pull request #272 from appwrite/chore-turn-dev-analytics-into-debug-logs
chore: change console.log into console.debug to make filtering easier
This commit is contained in:
@@ -24,7 +24,7 @@ export function trackEvent(name: string, data: object = null): void {
|
||||
const path = get(page).route.id;
|
||||
|
||||
if (isDevelopment) {
|
||||
console.log(`[Analytics] Event ${name} ${path}`, data);
|
||||
console.debug(`[Analytics] Event ${name} ${path}`, data);
|
||||
} else {
|
||||
analytics.track(name, { ...data, path });
|
||||
sendEventToGrowth(name, path, data);
|
||||
@@ -37,7 +37,7 @@ export function trackPageView(path: string) {
|
||||
}
|
||||
|
||||
if (isDevelopment) {
|
||||
console.log(`[Analytics] Pageview ${path}`);
|
||||
console.debug(`[Analytics] Pageview ${path}`);
|
||||
} else {
|
||||
analytics.page({
|
||||
path
|
||||
|
||||
@@ -40,7 +40,7 @@ function sendToAnalytics(metric: Metric, options: Options) {
|
||||
};
|
||||
|
||||
if (options.debug) {
|
||||
console.log('[Analytics]', metric.name, JSON.stringify(body, null, 2));
|
||||
console.debug('[Analytics]', metric.name, JSON.stringify(body, null, 2));
|
||||
}
|
||||
|
||||
const blob = new Blob([new URLSearchParams(body).toString()], {
|
||||
|
||||
Reference in New Issue
Block a user