[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill:01M757HBGFCMTJTQB45JQFXCC0":3,"skill-same:01M757HBGFCMTJTQB45JQFXCC0":85},{"skillNo":4,"name":5,"nameZh":6,"description":7,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":16,"categories":17,"keywords":18,"publishedAt":19,"linkOnly":20,"markdownContent":21,"markdownBody":22,"frontMatter":23,"refName":38,"commitSha":39,"skillDirectory":40,"forksCount":14,"repositoryHtmlUrl":41,"repositoryHomepageUrl":6,"ownerHtmlUrl":42,"ownerBlogUrl":43,"ownerDescription":6,"updatedAt":44,"install":45,"resources":58},"01M757HBGFCMTJTQB45JQFXCC0","pretext",null,"Build creative browser demos with DOM-free text layout.","rakaarwaky\u002Fagents-arwaky","rakaarwaky","https:\u002F\u002Favatars.githubusercontent.com\u002Fu\u002F245127434?v=4","01M7574QFJB21S6PPNCK78WX68","Raka Arwaky","01M7574QG54PRT44Q4KMQFXY6B",0,"MIT","https:\u002F\u002Fgithub.com\u002Frakaarwaky\u002Fagents-arwaky\u002Fblob\u002Fmain\u002Fskills\u002Fweb-design\u002Fpretext\u002FSKILL.md",[],[],"2026-11-12 13:55:43",false,"---\nname: pretext\ndescription: \"Build creative browser demos with DOM-free text layout.\"\nwhen-to-use: \"Use when the user wants a pretext creative demo — text flowing around a moving shape, ASCII-art effects using real words, text-as-geometry games, kinetic typography, multiline shrink-wrap UI, or per-glyph physics.\"\nargument-hint: \"\u003Cpattern> [output.html]\"\nmetadata:\n  tags:\n    - creative-coding\n    - typography\n    - pretext\n    - ascii-art\n    - canvas\n    - generative\n    - text-layout\n    - kinetic-typography\n  related_skills:\n    - p5js\n    - architecture-diagram\n---\n\n# Pretext Creative Demos\n\n[`@chenglou\u002Fpretext`](https:\u002F\u002Fgithub.com\u002Fchenglou\u002Fpretext) is a 15KB\nzero-dependency TypeScript library by Cheng Lou (React core, ReasonML,\nMidjourney) for **DOM-free multiline text measurement and layout**: given\n`(text, font, width)`, it returns line breaks, per-line widths, per-grapheme\npositions, and total height via canvas measurement, no reflow. It is a creative\nprimitive: reflow paragraphs around a moving sprite at 60fps, build games whose\nlevel geometry is real words, shatter text into particles, or pack\nshrink-wrapped multiline UI with zero `getBoundingClientRect` thrash.\n\nThis skill makes **cool demos** with it — the kind people post to X. The\ncommunity demo corpus is at `pretext.cool` and `chenglou.me\u002Fpretext`.\n\n## Global rules\n\n- **Creative standard.** Pretext returns numbers; you draw the thing. Don't\n  ship a \"hello world\" demo — the `hello-orb-flow.html` template is the\n  *starting* point; every delivered demo adds intentional color, motion,\n  composition, and one visual detail the user didn't ask for. Dark backgrounds\n  with considered palettes (amber-on-black, editorial white-on-charcoal,\n  risograph pastels). Proportional fonts are the point — lean into \"not\n  monospaced\". Use real source text, never lorem ipsum. First-paint\n  excellence: no loading states, no blank frames.\n- **Scope.** Use pretext only when the demo needs to know line breaks *before*\n  rendering. Don't use for static CSS\u002FHTML layouts, rich text editors, image →\n  text (use `ascii-art` \u002F `ascii-video` skills), or canvas generative art with\n  no text role (use `p5js`).\n- **Stack.** Single self-contained HTML file per demo, no build step:\n  `@chenglou\u002Fpretext` via esm.sh CDN, Canvas 2D for rendering, `Intl.Segmenter`\n  for grapheme splits, raw DOM events for interaction. Details:\n  [`references\u002Fstack-and-use-cases.md`](references\u002Fstack-and-use-cases.md).\n- **API invariants.** Call `prepare()`\u002F`prepareWithSegments()` once per\n  text+font pair and cache the handle; set `ctx.font` once per frame; keep the\n  `prepare()` font string exactly in sync with the rendered CSS; use\n  `Intl.Segmenter` for grapheme splits. Pitfalls + verification:\n  [`references\u002Fpitfalls.md`](references\u002Fpitfalls.md).\n\n## Routing\n\n| Step | Reference | Purpose |\n| ---- | --------- | ------- |\n| API & use cases | [`references\u002Fstack-and-use-cases.md`](references\u002Fstack-and-use-cases.md) | The two use cases (measure-only vs measure+render), streaming variable-width flow, helpers, pinned CDN import. |\n| Pick a pattern | [`references\u002Fpatterns.md`](references\u002Fpatterns.md) | Community demo patterns and which pretext API each uses. Pick one, riff on it — don't invent a new category unless asked. |\n| Pitfalls & verification | [`references\u002Fpitfalls.md`](references\u002Fpitfalls.md) | Performance notes, 8 common pitfalls, 10-item verification checklist. |\n| Starters | `templates\u002Fhello-orb-flow.html`, `templates\u002Fdonut-orbit.html` | Working starters: reflow around a moving orb; measured ASCII logo obstacles with draggable wire shapes. |\n| Inspiration | [`references\u002Fcommunity-demos.md`](references\u002Fcommunity-demos.md) | Clone-worthy community demos and the official playground gallery. |\n","# Pretext Creative Demos\n\n[`@chenglou\u002Fpretext`](https:\u002F\u002Fgithub.com\u002Fchenglou\u002Fpretext) is a 15KB\nzero-dependency TypeScript library by Cheng Lou (React core, ReasonML,\nMidjourney) for **DOM-free multiline text measurement and layout**: given\n`(text, font, width)`, it returns line breaks, per-line widths, per-grapheme\npositions, and total height via canvas measurement, no reflow. It is a creative\nprimitive: reflow paragraphs around a moving sprite at 60fps, build games whose\nlevel geometry is real words, shatter text into particles, or pack\nshrink-wrapped multiline UI with zero `getBoundingClientRect` thrash.\n\nThis skill makes **cool demos** with it — the kind people post to X. The\ncommunity demo corpus is at `pretext.cool` and `chenglou.me\u002Fpretext`.\n\n## Global rules\n\n- **Creative standard.** Pretext returns numbers; you draw the thing. Don't\n  ship a \"hello world\" demo — the `hello-orb-flow.html` template is the\n  *starting* point; every delivered demo adds intentional color, motion,\n  composition, and one visual detail the user didn't ask for. Dark backgrounds\n  with considered palettes (amber-on-black, editorial white-on-charcoal,\n  risograph pastels). Proportional fonts are the point — lean into \"not\n  monospaced\". Use real source text, never lorem ipsum. First-paint\n  excellence: no loading states, no blank frames.\n- **Scope.** Use pretext only when the demo needs to know line breaks *before*\n  rendering. Don't use for static CSS\u002FHTML layouts, rich text editors, image →\n  text (use `ascii-art` \u002F `ascii-video` skills), or canvas generative art with\n  no text role (use `p5js`).\n- **Stack.** Single self-contained HTML file per demo, no build step:\n  `@chenglou\u002Fpretext` via esm.sh CDN, Canvas 2D for rendering, `Intl.Segmenter`\n  for grapheme splits, raw DOM events for interaction. Details:\n  [`references\u002Fstack-and-use-cases.md`](references\u002Fstack-and-use-cases.md).\n- **API invariants.** Call `prepare()`\u002F`prepareWithSegments()` once per\n  text+font pair and cache the handle; set `ctx.font` once per frame; keep the\n  `prepare()` font string exactly in sync with the rendered CSS; use\n  `Intl.Segmenter` for grapheme splits. Pitfalls + verification:\n  [`references\u002Fpitfalls.md`](references\u002Fpitfalls.md).\n\n## Routing\n\n| Step | Reference | Purpose |\n| ---- | --------- | ------- |\n| API & use cases | [`references\u002Fstack-and-use-cases.md`](references\u002Fstack-and-use-cases.md) | The two use cases (measure-only vs measure+render), streaming variable-width flow, helpers, pinned CDN import. |\n| Pick a pattern | [`references\u002Fpatterns.md`](references\u002Fpatterns.md) | Community demo patterns and which pretext API each uses. Pick one, riff on it — don't invent a new category unless asked. |\n| Pitfalls & verification | [`references\u002Fpitfalls.md`](references\u002Fpitfalls.md) | Performance notes, 8 common pitfalls, 10-item verification checklist. |\n| Starters | `templates\u002Fhello-orb-flow.html`, `templates\u002Fdonut-orbit.html` | Working starters: reflow around a moving orb; measured ASCII logo obstacles with draggable wire shapes. |\n| Inspiration | [`references\u002Fcommunity-demos.md`](references\u002Fcommunity-demos.md) | Clone-worthy community demos and the official playground gallery. |\n",{"name":5,"metadata":24,"description":7,"when-to-use":36,"argument-hint":37},{"tags":25,"related_skills":33},[26,27,5,28,29,30,31,32],"creative-coding","typography","ascii-art","canvas","generative","text-layout","kinetic-typography",[34,35],"p5js","architecture-diagram","Use when the user wants a pretext creative demo — text flowing around a moving shape, ASCII-art effects using real words, text-as-geometry games, kinetic typography, multiline shrink-wrap UI, or per-glyph physics.","\u003Cpattern> [output.html]","main","e0708985ab2d620bc6e8fe741eaa4ec1960269e3","skills\u002Fweb-design\u002Fpretext","https:\u002F\u002Fgithub.com\u002Frakaarwaky\u002Fagents-arwaky","https:\u002F\u002Fgithub.com\u002Frakaarwaky","https:\u002F\u002Fbuymeacoffee.com\u002Frakaarwaky","2026-11-15 04:28:37",{"source":8,"skillName":5,"commands":46,"prompt":56,"zipAvailable":57},[47,50,53],{"tool":48,"command":49},"npx","npx skills add rakaarwaky\u002Fagents-arwaky --skill pretext",{"tool":51,"command":52},"bunx","bunx skills add rakaarwaky\u002Fagents-arwaky --skill pretext",{"tool":54,"command":55},"pnpm","pnpm dlx skills add rakaarwaky\u002Fagents-arwaky --skill pretext","安装技能，技能地址：https:\u002F\u002Fgithub.com\u002Frakaarwaky\u002Fagents-arwaky\u002Fblob\u002Fmain\u002Fskills\u002Fweb-design\u002Fpretext\u002FSKILL.md",true,[59,65,69,73,77,81],{"path":60,"resourceType":61,"resourceTypeDesc":62,"sizeBytes":63,"sourceHtmlUrl":64},"references\u002Fcommunity-demos.md","REFERENCE","参考文档",848,"https:\u002F\u002Fgithub.com\u002Frakaarwaky\u002Fagents-arwaky\u002Fblob\u002Fmain\u002Fskills\u002Fweb-design\u002Fpretext\u002Freferences\u002Fcommunity-demos.md",{"path":66,"resourceType":61,"resourceTypeDesc":62,"sizeBytes":67,"sourceHtmlUrl":68},"references\u002Fpatterns.md",10450,"https:\u002F\u002Fgithub.com\u002Frakaarwaky\u002Fagents-arwaky\u002Fblob\u002Fmain\u002Fskills\u002Fweb-design\u002Fpretext\u002Freferences\u002Fpatterns.md",{"path":70,"resourceType":61,"resourceTypeDesc":62,"sizeBytes":71,"sourceHtmlUrl":72},"references\u002Fpitfalls.md",3994,"https:\u002F\u002Fgithub.com\u002Frakaarwaky\u002Fagents-arwaky\u002Fblob\u002Fmain\u002Fskills\u002Fweb-design\u002Fpretext\u002Freferences\u002Fpitfalls.md",{"path":74,"resourceType":61,"resourceTypeDesc":62,"sizeBytes":75,"sourceHtmlUrl":76},"references\u002Fstack-and-use-cases.md",3457,"https:\u002F\u002Fgithub.com\u002Frakaarwaky\u002Fagents-arwaky\u002Fblob\u002Fmain\u002Fskills\u002Fweb-design\u002Fpretext\u002Freferences\u002Fstack-and-use-cases.md",{"path":78,"resourceType":61,"resourceTypeDesc":62,"sizeBytes":79,"sourceHtmlUrl":80},"templates\u002Fdonut-orbit.html",53211,"https:\u002F\u002Fgithub.com\u002Frakaarwaky\u002Fagents-arwaky\u002Fblob\u002Fmain\u002Fskills\u002Fweb-design\u002Fpretext\u002Ftemplates\u002Fdonut-orbit.html",{"path":82,"resourceType":61,"resourceTypeDesc":62,"sizeBytes":83,"sourceHtmlUrl":84},"templates\u002Fhello-orb-flow.html",3443,"https:\u002F\u002Fgithub.com\u002Frakaarwaky\u002Fagents-arwaky\u002Fblob\u002Fmain\u002Fskills\u002Fweb-design\u002Fpretext\u002Ftemplates\u002Fhello-orb-flow.html",[86,94,101,108,115,121],{"skillNo":87,"name":88,"nameZh":6,"description":89,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":90,"categories":91,"keywords":92,"publishedAt":93},"01M78SFXSH86CW16Z5FEXMSJXH","github-workflow","Umbrella for GitHub auth, repo management, issues, PRs, Mergify, and releases. Subsumes github-auth and repo-manager.","https:\u002F\u002Fgithub.com\u002Frakaarwaky\u002Fagents-arwaky\u002Fblob\u002Fmain\u002Fskills\u002Fgit\u002Fgithub-workflow\u002FSKILL.md",[],[],"2026-11-15 14:19:17",{"skillNo":95,"name":96,"nameZh":6,"description":97,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":98,"categories":99,"keywords":100,"publishedAt":93},"01M78SF81R7NVSCXAT8YQ255HM","brave-automation","baa CLI: Brave profiles, Google sessions, credentials.","https:\u002F\u002Fgithub.com\u002Frakaarwaky\u002Fagents-arwaky\u002Fblob\u002Fmain\u002Fskills\u002Fbrave-automation\u002Fbrave-automation\u002FSKILL.md",[],[],{"skillNo":102,"name":103,"nameZh":6,"description":104,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":105,"categories":106,"keywords":107,"publishedAt":93},"01M78SEY7TS908JM8KVPBM6HBN","aes","AES docs, layers, rule fixes, and legacy migration.","https:\u002F\u002Fgithub.com\u002Frakaarwaky\u002Fagents-arwaky\u002Fblob\u002Fmain\u002Fskills\u002Farchitechture\u002Faes\u002FSKILL.md",[],[],{"skillNo":109,"name":110,"nameZh":6,"description":111,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":112,"categories":113,"keywords":114,"publishedAt":19},"01M757H8K38ETN8F4ANBBRWY4G","popular-web-designs","54 real design systems (Stripe, Linear, Vercel) as HTML\u002FCSS.","https:\u002F\u002Fgithub.com\u002Frakaarwaky\u002Fagents-arwaky\u002Fblob\u002Fmain\u002Fskills\u002Fweb-design\u002Fpopular-web-designs\u002FSKILL.md",[],[],{"skillNo":116,"name":34,"nameZh":6,"description":117,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":118,"categories":119,"keywords":120,"publishedAt":19},"01M757H5DM7QPN9H391572NH5B","p5.js sketches: gen art, shaders, interactive, 3D.","https:\u002F\u002Fgithub.com\u002Frakaarwaky\u002Fagents-arwaky\u002Fblob\u002Fmain\u002Fskills\u002Fweb-design\u002Fp5js\u002FSKILL.md",[],[],{"skillNo":122,"name":123,"nameZh":6,"description":124,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":125,"categories":126,"keywords":127,"publishedAt":19},"01M757H2XPN2T1GEXWAGRXHE8W","design-md","Author\u002Fvalidate\u002Fexport Google's DESIGN.md design-token spec files.","https:\u002F\u002Fgithub.com\u002Frakaarwaky\u002Fagents-arwaky\u002Fblob\u002Fmain\u002Fskills\u002Fweb-design\u002Fdesign-md\u002FSKILL.md",[],[]]