building-canvases
यह क्या करती है
यह स्किल कैनवास बनाती और अपडेट करती है, जो PostHog के अंदर रहने वाले छोटे इंटरैक्टिव ऐप हैं और एक सुरक्षित फ़्रेम में चलते हैं। यह उन लोगों के लिए है जिन्हें PostHog में अलग कोड प्रोजेक्ट के बिना कस्टम बोर्ड, दस्तावेज़, फ़ॉर्म या छोटा टूल चाहिए।
कब इस्तेमाल करें
- ✓जब आपको PostHog के अंदर रहने वाला कस्टम बोर्ड, फ़ॉर्म या दस्तावेज़ चाहिए।
- ✓जब किसी मौजूदा कैनवास ऐप को बदलना या ठीक करना हो।
- ✓जब आप अपने PostHog डेटा से एक छोटा विज़ुअल टूल बनवाना चाहें।
Skill का लिंक
https://github.com/PostHog/posthog/blob/master/products/canvas/skills/building-canvases/SKILL.mdइसे कॉपी करके अपने AI (Claude, ChatGPT या Cursor) में पेस्ट करें और निर्देशों का पालन करने को कहें।
कैसे इस्तेमाल करें
सबसे आसान तरीका: मैसेज कॉपी करके अपने AI में पेस्ट करें। वह skill पढ़कर निर्देशों का पालन करेगा।
पेस्ट करने के लिए तैयार मैसेज
Claude Code, Codex या Cursor के लिए: प्रोजेक्ट फ़ोल्डर में चलाएँ और skill इंस्टॉल हो जाएगी।
SKILL.md डाउनलोड करें और अपने एजेंट के skills फ़ोल्डर में रखें।
AI से क्या माँगें: उदाहरण
“एक कैनवास बनाइए जो हमारे साइनअप के आँकड़े दिखाए और मुझे तारीख की सीमा चुनने दे।”
हर हफ़्ते 5 नई skills, 1 मिनट में पढ़ें।
यह कैसे काम करती है
AI PostHog के अंदर कैनवास का सोर्स लिखता है, जाँचता है कि वह केवल अनुमत लाइब्रेरी और घोषित डेटा स्रोत इस्तेमाल करता है, और फिर उसे प्रकाशित करता है। PostHog कैनवास बनाता है, और नया बिल्ड तैयार होने तक अपना आख़िरी सफल बिल्ड दिखाता है।
तकनीकी सामग्री (मूल SKILL.md)
लेखक का मूल टेक्स्ट, अंग्रेज़ी में, सीधे GitHub से।
Building canvases
A canvas is a client-side browser application that runs in a sandboxed iframe inside PostHog.
Its source lives in PostHog — not in a repository — and you read and write it through the
canvas-* tools. Never write a canvas to a local file; publishing through the tool is what
saves it.
Canvas work can start from any ordinary task. A dedicated canvas mode or pre-created canvas is not required. When the user asks for a board, document, form, visualization, or small app that should live in PostHog, treat that as a canvas request and follow this skill.
This skill owns freeform canvases (standalone apps). Two other canvas kinds exist: grid
canvases (widget grids, including the user's home canvas) and component canvases (reusable
widgets grids place). When the target is a grid or home canvas, a placement, or a reusable
widget/component, load composing-grid-canvases instead — it owns the store search → configure →
fork → build ladder and the layout patch loop. Authoring a component's source still uses the
implementation companions below.
Resolve the target canvas
- If the task names a canvas id (canvas-initiated tasks do), that is the target. Do not create another.
- Otherwise the target channel is the one the task was created in — named in the task's context
(the
channel_contextblock or the generation instructions). List that channel's canvases withcanvas-list(scope withchannel). If one is clearly what the request refers to — an earlier iteration of the same board or tool — build on it instead of creating a near-duplicate, and say so in your reply so the user knows where the result landed. - Only when nothing existing fits, create one with
canvas-createin that same channel, named with a short descriptive title drawn from the request — never "Untitled canvas". - Never survey channels to choose a target yourself: use
channel-listonly to resolve a channel the USER named to its id. Its listing puts the personal #me channel first, and #me is never a default — a canvas filed there is invisible to everyone else. If the task names neither a canvas nor a channel, ask which channel to use instead of guessing.
Load the companion skills for the implementation
This skill owns canvas selection and the authoring lifecycle. The companion skills hold the implementation contracts. Load every companion that applies before writing source:
building-react-quill-canvasesfor dashboards, data boards, forms, tools, application-like state, or anything that should look native to PostHog. It owns allowed imports, Quill composition, theming, charts, loading and error states, and the date picker.building-html-canvasesfor documents, articles, focused experiments, generative graphics,<canvas>, or WebGL work where application components add no useful structure. It owns semantic markup, direct browser APIs, animation cleanup, and non-Quill theming.querying-canvas-datawhenever the canvas reads PostHog data, captures events, or navigates. It owns thephSDK, saved-insight preference, result shapes, variables, date ranges, progressive per-query loading, and declared data capabilities. Load it alongside either implementation skill when data is involved.validating-and-publishing-canvasesfor every canvas. It owns project shape, capability declarations, validation diagnostics, guarded publishes, drafts, builds, and conflict recovery.
Mix implementation approaches when appropriate: React can own application chrome while browser graphics code owns a canvas element, or a mostly static page can mount one interactive island.
This is a judgment call, not a persisted mode — ask the user only when the choice changes a user-visible requirement you cannot infer.
Blocks
A canvas can contain premade blocks: numbers, goals, trends, top lists, funnels, retention, saved insights, live event feeds, SQL tables, filters, compare and refresh controls, and callouts.
They are React components in src/blocks/ that people drag into the canvas in the desktop app, so they are part of your source.
Read references/blocks.md before you change a canvas that has src/blocks/runtime.tsx.
Params
Expose the values a person may want to change as params. They can then change them in the desktop editor without a new task. Params are optional, but add them to each panel, card, or tool that has values worth changing: titles, copy, ev
अक्सर पूछे जाने वाले सवाल
क्या मुझे ऐप खुद होस्ट करना होगा?
नहीं। कैनवास का सोर्स PostHog में सेव रहता है और वहीं रेंडर होता है।
क्या कैनवास मेरा PostHog डेटा लोड कर सकता है?
हाँ। वह PostHog के अंदर बने ब्रिज से डेटा पढ़ता है, और उसे घोषित करना होगा कि वह कौन सी इनसाइट और इवेंट इस्तेमाल करता है।
क्या यह किसी और के बदलाव ओवरराइट कर सकता है?
PostHog ऐसा प्रकाशन रोकता है जो नए काम को ओवरराइट करे, इसलिए AI को दोबारा प्रकाशित करने से पहले नवीनतम संस्करण पढ़ना होगा।
जानकारी
लेखक का मूल विवरण
Create or edit a PostHog freeform canvas — a sandboxed browser application (data board, document, form, small tool, graphics experiment) stored in PostHog and rendered by the desktop/web app. Use when a task asks to build, generate, update, or fix a standalone canvas app, or when a freeform canvas id is given as the publish target. For grid/home canvases, widget placements, or reusable components, use composing-grid-canvases instead. Covers resolving or creating the target canvas, choosing an implementation approach (React + Quill vs plain HTML/browser APIs), the read → edit → validate → publi
repo: PostHog/posthog
लोकप्रियता
- GitHub स्टार
- 41k
- रैंकिंग में स्थान
- #6838
- लाइसेंस
- —
- अपडेट की गई
- 2/11/2026
कमेंट
- …
इस repository की और skills
depot-ci
41kयह आपके एजेंट को Depot CI वर्कफ़्लो सेट अप करने, चलाने और माइग्रेट करने में मदद करती है, साथ ही रन के लॉग पढ़ने में।
depot-container-builds
41kयह आपके एजेंट को Depot के रिमोट बिल्डर पर Docker इमेज बनाने में मदद करती है, जिसमें मल्टी-प्लेटफ़ॉर्म इमेज और बिल्ड सुधार शामिल हैं।
depot-github-runners
41kयह आपके एजेंट को GitHub Actions जॉब Depot के मैनेज्ड रनर पर ले जाने, रनर का साइज़ और लेबल चुनने, और रनर सेटअप की समस्याएँ ठीक करने में मदद करती है।
editing-agents-md
41kयह आपके एजेंट को तय करने में मदद करती है कि कोई नियम AGENTS.md या CLAUDE.md में जाए या नहीं, और उसे ऐसे लिखे कि फ़ाइल भारी न हो।
मिलती-जुलती 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 फॉलो करवाता है।