shared-contracts

Community

Align shared Zod contracts across repo.

Authordtaborda
Version1.0.0
Installs0

System Documentation

What problem does it solve?

This Skill ensures the monorepo never drifts into inconsistent DTOs or inline types by centralizing every shared Zod schema and inferred type in @template/contracts.

Core Features & Use Cases

  • Centralized schema conventions: Always define schemas in packages/contracts/src/, use Schema suffixes, and infer types to keep DTOs reliable.
  • Re-export discipline: Update index.ts so every package can import contracts via subpaths or the barrel without duplication.
  • Version-aware edits: Changing field names or required status triggers the contract-versioning workflow to prevent breaking clients.
  • Use Case: When adding a new API request shape, define it once, export it properly, and reuse the contract from ui and server packages.

Quick Start

Define a new Zod schema in packages/contracts, infer its type, add it to the relevant file, and update the barrel export so shared contracts stay synchronized.

Dependency Matrix

Required Modules

None required

Components

references

💻 Claude Code Installation

Recommended: Let Claude install automatically. Simply copy and paste the text below to Claude Code.

Please help me install this Skill:
Name: shared-contracts
Download link: https://github.com/dtaborda/startup-saas-template/archive/main.zip#shared-contracts

Please download this .zip file, extract it, and install it in the .claude/skills/ directory.
View Source Repository

Agent Skills Search Helper

Install a tiny helper to your Agent, search and equip skill from 471,000+ vetted skills library on demand.