create-evlog-framework-integration
БесплатноБез исполняемых скриптовНе проверенCreate a new evlog framework integration to add automatic wide-event logging to an HTTP framework. Use when adding middleware/plugin support for a framework…
от evloghq★ 1 955 звёзд на GitHubОб этом скилле
Create evlog Framework Integration
Add a new framework integration to evlog. The recommended path is the manifest mode built on defineFrameworkIntegration from evlog/toolkit, for any framework with a request/response middleware shape. For frameworks with a fundamentally different lifecycle you'll fall back to the lower-level createMiddlewareLogger.
Two paths
- Manifest mode (preferred, ~30–80 lines of glue). Call
defineFrameworkIntegration({ name, extractRequest, attachLogger, storage? })once at module level, then write a tiny middleware that callsintegration.start(ctx, options)and runs the framework'snext()insiderunWith. Reference implementations: all ofpackages/evlog/src/{hono,express,fastify,elysia,nestjs,orpc,react-router,sveltekit,workers}/index.tsuse it. - Custom mode: use
createMiddlewareLoggerdirectly when the framework's lifecycle doesn't fit a standard middleware. Current custom-mode integrations: Next.js (src/next/), Nitro v2/v3 (src/nitro/,src/nitro-v3/), Eve (src/eve/).
Manifest mode now covers all classic HTTP frameworks. Use custom mode only when you can't extract a request synchronously at the start of the lifecycle (server actions, module-level hooks, agent turns).
Required API surface (from AGENTS.md)
Every framework integration must expose:
evlog()middleware/plugin accepting the fullBaseEvlogOptions(drain,enrich,keep,include,exclude,routes,plugins)useLogger()(ALS-backed). Two sanctioned exceptions: Workers (ALS needs a compat flag there;defineWorkerFetchattaches the logger instead) and Effect (the logger is theEvlogLoggerservice in the Effect context)log.fork()support (automatic whenstorageis provided to the manifest)- The framework-native accessor (
c.get('log'),req.log,event.locals.log, …)
PR Title
feat({framework}): add {Framework} middleware integration
Scope timing caveat: the semantic PR check reads its scope list from the base branch, so a brand-new scope can't validate the very PR that introduces it. Either register the scope in a small preceding PR, or use an unscoped title (feat: add {Framework} middleware integration) on the introducing PR.
Touchpoints Checklist
| # | File | Action |
|---|---|---|
| 1 | packages/evlog/src/{framework}/index.ts |
Create integration source |
| 2 | packages/evlog/tsdown.config.ts |
Add build entry + external |
| 3 | packages/evlog/package.json |
Add exports + typesVersions + optional peer dep + keyword |
| 4 | packages/evlog/test/frameworks/{framework}.test.ts |
Create tests (real request driver + describeStandardHttpMatrix) |
| 5 | packages/evlog/test/toolkit/__snapshots__/api-surface.test.ts.snap |
Regenerated by pnpm run build + pnpm test |
| 6 | apps/docs/content/4.integrate/frameworks/{NN}.{framework}.md |
Create framework docs page |
| 7 | apps/docs/content/4.integrate/frameworks/00.overview.md |
Add table row + card |
| 8 | apps/docs/content/1.start/3.installation.md |
Add card in "Choose Your Framework" |
| 9 | apps/docs/content/0.landing.md |
Add framework code snippet slot |
| 10 | apps/docs/app/components/features/FeatureFrameworks.vue |
Add framework tab |
| 11 | skills/review-logging-patterns/SKILL.md |
Add framework setup section + update frontmatter description |
| 12 | packages/evlog/README.md |
Add framework section + row in the Framework Support table |
| 13 | examples/{framework}/ |
Create example app with test UI (auto-discovered by pnpm example {framework}, no root script needed) |
| 14 | .changeset/{framework}-integration.md |
Create changeset (minor) |
| 15 | .github/workflows/semantic-pull-request.yml + .github/pull_request_template.md |
Register {framework} as a PR scope in both files |
Important: Do NOT consider the task complete until all 15 touchpoints have been addressed.
Naming Conventions
| Placeholder | Example (Hono) | Usage |
|---|---|---|
{framework} |
hono |
Directory names, import paths, file names, PR scope |
{Framework} |
Hono |
PascalCase in type/interface names |
Shared Utilities
All integrations share the same core utilities. Never reimplement logic that exists in shared/. These are also publicly available as evlog/toolkit for community-built integrations (see Custom Integration docs).
| Utility | Location | Purpose |
|---|---|---|
defineFrameworkIntegration |
../shared/integration |
Manifest factory: extract request, create logger, attach, run with ALS |
createMiddlewareLogger |
../shared/middleware |
Lower-level lifecycle (custom mode): logger creation, route filtering, tail sampling, emit, enrich, drain |
BaseEvlogOptions |
../shared/middleware |
Base user-facing options type with drain, enrich, keep, include, exclude, routes, plugins |
| `c |
Установить create-evlog-framework-integration в Claude Code и Claude Desktop
Зарегайся, чтобы установить скилл
Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.
- Открой команду установки в одну строку
- Сохраняй скиллы в синхронизируемую библиотеку
- Уведомления, когда скиллы обновляются
Разрешённые инструменты
Инструменты, которые скиллу разрешено вызывать.
Без ограничений — скилл может использовать любой инструмент.
FAQ
Что делает скилл create-evlog-framework-integration?
Create a new evlog framework integration to add automatic wide-event logging to an HTTP framework. Use when adding middleware/plugin support for a framework (e.g., Koa, H3 standalone, Deno Fresh, etc.) to the evlog package. Covers source code, build config, package exports, tests, example app, and all documentation.
Как установить скилл create-evlog-framework-integration?
Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.
Скилл create-evlog-framework-integration запускает скрипты?
Нет, скилл состоит только из инструкций (SKILL.md), без исполняемых скриптов.
Похожие скиллы
mcp-builder
Guide for creating high-quality MCP (Model Context Protocol) servers that enable LLMs to interact with external services through well-designed tools. Use when…
от Anthropicclaude-api
Reference for the Claude API / Anthropic SDK — model ids, pricing, params, streaming, tool use, MCP, agents, caching, token counting, model migration. TRIGGER…
от Anthropicalgorithmic-art
Creating algorithmic art using p5.js with seeded randomness and interactive parameter exploration. Use this when users request creating art using code…
от Anthropicmcp-integration
This skill should be used when the user asks to "add MCP server", "integrate MCP", "configure MCP in plugin", "use .mcp.json", "set up Model Context…
от Anthropic