Communityコーディング&開発github.com

mcollina/fastify-best-practices

Fastify を使用した Node.js バックエンドサーバーと REST API の開発をガイドします。ルート定義、プラグイン実装、JSON Schema バリデーション、エラーハンドリング、パフォーマンス最適化、認証、CORS とセキュリティヘッダー設定、データベース統合、WebSocket、本番デプロイまでをカバー。

fastify-best-practices とは?

このスキルは、Fastify フレームワークを使用して Node.js バックエンドサーバーと REST API を構築・設定・デバッグするためのベストプラクティスを提供します。TypeScript と JavaScript の両方をサポートし、ルート定義、プラグイン、JSON Schema バリデーション、エラーハンドリング、パフォーマンス最適化、認証(JWT など)、CORS、Helmet によるセキュリティヘッダー、データベース統合(PostgreSQL、MongoDB)、WebSocket、本番デプロイ(Docker、PM2)など、Fastify アプリケーション開発のあらゆる側面をカバーします。また、Fastify のリクエストライフサイクル(フック、シリアライゼーション、Pino を使用したロギング)や、TypeScript 統合(strip types)についても詳しく解説します。主に Cursor、Claude Code、Codex などの AI エージェント環境で動作し、fastify.config、server.ts、app.ts などのファイルを扱う際に自動的にトリガーされます。

対応~Claude Code~Codex CLI~Cursor
npx skills add https://github.com/mcollina/skills/tree/main/skills/fastify-best-practices

Installed? Explore more コーディング&開発 skills: steipete/bluebubbles, steipete/eightctl, steipete/blucli · View all 6 →

お気に入りのAIに質問する

このエージェントスキルを事前に読み込んだ状態で新しいチャットを開きます。

ドキュメント

fastify-best-practices は何をしますか?

Fastify を使用した Node.js バックエンドサーバーと REST API の開発を TypeScript または JavaScript でガイドします。Fastify アプリケーションの構築、設定、デバッグ時に使用します。具体的には、ルート定義、プラグイン実装、JSON Schema バリデーション設定、エラーハンドリング、パフォーマンス最適化、認証管理、CORS とセキュリティヘッダー設定、データベース統合、WebSocket 対応、本番デプロイなどをカバーします。Fastify のリクエストライフサイクル全体(フック、シリアライゼーション、Pino によるロギング)と、strip types による TypeScript 統合についても解説します。トリガーとなる用語: Fastify、Node.js サーバー、REST API、API ルート、バックエンドフレームワーク、fastify.config、server.ts、app.ts。

Individual skills in this repo

This repo contains 4 individual skills — each has its own dedicated page.

mcollina/documentation

Creates, structures, and reviews technical documentation following the Diátaxis framework (tutorials, how-to guides, reference, and explanation pages). Use when a user needs to write or reorganize docs, structure a tutorial vs. a how-to guide, build reference docs or API documentation, create explanation pages, choose between Diátaxis documentation types, or improve existing documentation structure. Trigger terms include: documentation structure, Diátaxis, tutorials vs how-to guides, organize docs, user guide, reference docs, technical writing.

mcollina/node

Provides domain-specific best practices for Node.js development with TypeScript, covering type stripping, async patterns, error handling, streams, modules, testing, performance, caching, logging, and more. Use when setting up Node.js projects with native TypeScript support, configuring type stripping (--experimental-strip-types), writing Node 22+ TypeScript without a build step, or when the user mentions 'native TypeScript in Node', 'strip types', 'Node 22 TypeScript', '.ts files without compilation', 'ts-node alternative', or needs guidance on error handling, graceful shutdown, flaky tests, profiling, or environment configuration in Node.js. Helps configure tsconfig.json for type stripping, set up package.json scripts, handle module resolution and import extensions, and apply robust patterns across the full Node.js stack.

mcollina/nodejs-core

Debugs native module crashes, optimizes V8 performance, configures node-gyp builds, writes N-API/node-addon-api bindings, and diagnoses libuv event loop issues in Node.js. Use when working with C++ addons, native modules, binding.gyp, node-gyp errors, segfaults, memory leaks in native code, V8 optimization/deoptimization, libuv thread pool tuning, N-API or NAN bindings, build system failures, or any Node.js internals below the JavaScript layer.

mcollina/typescript-magician

Designs complex generic types, refactors `any` types to strict alternatives, creates type guards and utility types, and resolves TypeScript compiler errors. Use when the user asks about TypeScript (TS) types, generics, type inference, type guards, removing `any` types, strict typing, type errors, `infer`, `extends`, conditional types, mapped types, template literal types, branded/opaque types, or utility types like `Partial`, `Record`, `ReturnType`, and `Awaited`.

関連スキル