frontend-observability
यह क्या करती है
यह सिस्टम समझने में मदद करता है कि असली यूज़र आपकी वेब या मोबाइल ऐप के साथ कैसे इंटरैक्ट कर रहे हैं। यह इवेंट, परफ़ॉर्मेंस और एरर की जानकारी इकट्ठा करता है, और यह सुनिश्चित करता है कि डेटा भरोसेमंद तरीके से जमा हो, साथ ही यूज़र की प्राइवेसी का भी ध्यान रखा जाए।
कब इस्तेमाल करें
- ✓यह जानने के लिए कि यूज़र कौन से बटन सबसे ज़्यादा दबाते हैं।
- ✓असली यूज़र के लिए पेज लोड होने की स्पीड पर नज़र रखने के लिए।
- ✓ऐप के अंदर होने वाली एरर को पहचानने और रिपोर्ट करने के लिए।
Skill का लिंक
https://github.com/sickn33/agentic-awesome-skills/blob/main/plugins/agentic-awesome-skills-claude/skills/frontend-observability/SKILL.mdइसे कॉपी करके अपने AI (Claude, ChatGPT या Cursor) में पेस्ट करें और निर्देशों का पालन करने को कहें।
कैसे इस्तेमाल करें
सबसे आसान तरीका: मैसेज कॉपी करके अपने AI में पेस्ट करें। वह skill पढ़कर निर्देशों का पालन करेगा।
पेस्ट करने के लिए तैयार मैसेज
Claude Code, Codex या Cursor के लिए: प्रोजेक्ट फ़ोल्डर में चलाएँ और skill इंस्टॉल हो जाएगी।
SKILL.md डाउनलोड करें और अपने एजेंट के skills फ़ोल्डर में रखें।
AI से क्या माँगें: उदाहरण
“मैं जानना चाहता हूँ कि यूज़र मेरी वेबसाइट के कौन से फीचर सबसे ज़्यादा इस्तेमाल करते हैं और क्या उन्हें कोई एरर आ रही है।”
हर हफ़्ते 5 नई skills, 1 मिनट में पढ़ें।
यह कैसे काम करती है
यह आपकी ऐप में होने वाली ज़रूरी घटनाओं को रिकॉर्ड करके काम करता है। ये इवेंट अलग-अलग एनालिटिक्स टूल्स को भेजे जाते हैं, लेकिन अगर कोई एक टूल फेल हो जाए, तो बाकी टूल्स काम करते रहते हैं और ऐप में रुकावट नहीं आती। यह असली यूज़र की परफ़ॉर्मेंस भी मापता है और डेटा तभी भेजता है जब यूज़र इसकी इजाज़त दे।
तकनीकी सामग्री (मूल SKILL.md)
लेखक का मूल टेक्स्ट, अंग्रेज़ी में, सीधे GitHub से।
Frontend Observability (the field side)
When to Use
Use this skill when you need a portable, framework-agnostic field-side observability system for any React or React Native app. Establishes one typed event taxonomy (canonical event-name constants, never inline strings), a best-effort non-blocking provider fan-out so a failing or absent analytics provider can never...
Portable skill — readable by Claude Code, OpenCode, Codex, Cursor, Windsurf, and others. This skill describes a field-side observability system — event taxonomy, provider fan-out, real-user vitals, error reporting, consent — not a dashboard or a specific vendor. It is the field complement to the frontend-lighthouse skill: Lighthouse is the lab gate (synthetic, pre-merge); this is the field (what real users actually experience). It lives in a
services/analytics/module per the frontend-architecture skill.
The goal: you can answer "what are real users doing, and what are they experiencing?" — with a
typed event vocabulary (no stringly-typed track("clicked_thing") scattered everywhere), a
fan-out that is best-effort (a broken provider never breaks the app), real Core Web Vitals
from the field, and consent respected before anything fires.
0. The five core ideas
- Events are a typed vocabulary. Event names are canonical constants with a union type — never inline string literals. The taxonomy is reviewable in one file and the compiler rejects typos.
- Fan-out is best-effort and non-blocking.
track()dispatches to every provider, each in its own try/catch. A missing global, a thrown provider, an unloaded script — none can throw into the caller or stop the other providers. - One entry point, SSR-safe. A single
track(event, props)is the only way to record. It's reached through a context hook that no-ops outside a provider and on the server, so instrumented components render safely anywhere. - Field vitals complement lab budgets. Real-user LCP/INP/CLS are reported to the same fan-out. Lighthouse proves the build can be fast; field vitals prove it is — together they close the loop.
- Consent gates everything. No telemetry (events, vitals, error reports with PII) fires before opt-in. Consent state is checked at the fan-out boundary, not sprinkled through call sites.
1. Directory layout
The system is one service module plus its constants (per frontend-architecture).
src/
├── constants/
│ └── analytics.ts ← canonical event names + AnalyticsEvent union
├── services/analytics/
│ ├── index.ts ← barrel: track, adapters, types
│ ├── track.ts ← the best-effort fan-out (single entry point)
│ ├── adapters.ts ← one (event, props) => void per provider, window-guarded
│ ├── web-vitals.ts ← report real-user LCP/INP/CLS into track()
│ └── consent.ts ← consent gate read by the fan-out
├── providers/
│ └── AnalyticsProvider.tsx ← 'use client' context exposing useAnalytics().track
└── error/
└── ErrorBoundary.tsx ← reports caught render errors via the fan-out
2. The event taxonomy (typed, never inline)
One file owns every event name. Components reference constants; the union type makes typos a compile error and the catalog a single source of truth.
// constants/analytics.ts
export const ANALYTICS_EVENTS = {
PROJECT_CLICK: "project_click",
GITHUB_CLICK: "github_click",
RESUME_DOWNLOAD: "resume_download",
CONTACT_SUBMISSION: "contact_submission",
} as const;
export type AnalyticsEvent =
(typeof ANALYTICS_EVENTS)[keyof typeof ANALYTICS_EVENTS];
// CORRECT — typed constant, autocompletes, can't typo
track(ANALYTICS_EVENTS.GITHUB_CLICK, { url });
// WRONG — stringly-typed, drifts, no compile check
track("github-click"); // ❌ silently a different event from "github_click"
Hard rules:
- No inline event-name strings anywhere; only
ANALYTICS_EVENTS.*. - Event names are snake_case and stable — renaming one breaks historical dashboards, so treat the catalog as a contract.
- Keep
propsshapes small and PII-light (see §6); prefer ids over names, never raw emails.
3. Best-effort, non-blocking fan-out
track() is the single entry point. It iterates the adapter registry, guarding each call so one
provider can't affect the caller or the others.
// services/analytics/track.ts
…
अक्सर पूछे जाने वाले सवाल
'framework-agnostic' का क्या मतलब है?
इसका मतलब है कि यह सिस्टम किसी भी तरह के वेब या मोबाइल प्रोजेक्ट में इस्तेमाल हो सकता है, चाहे उसे बनाने में किसी भी टेक्नोलॉजी (फ्रेमवर्क) का इस्तेमाल हुआ हो, जैसे React या React Native।
'Core Web Vitals' क्या हैं?
ये कुछ ज़रूरी मेट्रिक्स हैं जो बताते हैं कि किसी वेब पेज का यूज़र एक्सपीरियंस कैसा है, जैसे लोड होने की स्पीड, इंटरैक्टिविटी और स्क्रीन पर लेआउट कितना स्थिर रहता है।
यूज़र की प्राइवेसी कैसे सुरक्षित रखी जाती है?
यह सिस्टम यूज़र की साफ़ सहमति मिलने के बाद ही डेटा (टेलीमेट्री) इकट्ठा और भेजता है, और इकट्ठा किए गए डेटा में ऐसी जानकारी नहीं रखी जाती जिससे किसी व्यक्ति की पहचान हो सके।
जानकारी
लेखक का मूल विवरण
A portable, framework-agnostic field-side observability system for any React or React Native app.
लोकप्रियता
- GitHub स्टार
- 48k
- रैंकिंग में स्थान
- #4670
- लाइसेंस
- MIT
- अपडेट की गई
- 15/10/2026
कमेंट
- …
इस repository की और skills
00-andruia-consultant
48kआपके एजेंट को AI प्रोजेक्ट शुरू करने या उन्हें बेहतर बनाने में मदद करता है। यह code का विश्लेषण करता है, tools सुझाता है और स्पेनिश भाषा में action plan बनाता है।
007
48kआपका एजेंट security audit और threat modeling करता है। यह प्रोजेक्ट को हमलों और कमजोरियों से बचाने में काम आता है।
10-andruia-skill-smith
48kआपके एजेंट को AI tools बनाने या उन्हें बेहतर करने में मदद करता है। यह तय करता है कि tools कैसे काम करेंगे, documentation लिखता है और structure की जांच करता है।
20-andruia-niche-intelligence
48kआपका एजेंट किसी खास industry का summary बनाता है। भरोसेमंद स्रोतों की मदद से यह प्रोजेक्ट का संदर्भ, नियम, इस्तेमाल के तरीके और जोखिम समझने में मदद करता है।
मिलती-जुलती skills
angular-developer
280kआपके एजेंट को Angular code बनाने और प्रोजेक्ट स्ट्रक्चर पर सलाह देने में मदद करता है। नए प्रोजेक्ट शुरू करने, code के हिस्से बनाने, या performance और accessibility सुधारने में उपयोगी है।
frontend-a11y
280kआपके एजेंट को web interfaces को सबके लिए accessible बनाने में मदद करता है। यह सुनिश्चित करता है कि websites और apps screen readers और keyboard navigation के साथ अच्छे से काम करें।
frontend-patterns
280kआपके एजेंट को React और Next.js में frontend development के modern patterns लागू करने में मदद करता है। यह performance optimize करता है, state manage करता है और best practices फॉलो करवाता है।