Skip to content
@typesharp-cli

TypeSharp

Official home of TypeSharp CLI · Modern tooling for full-stack .NET and TypeScript development.

TypeSharp CLI 🔷

Automatically generate TypeScript from C# — keep your frontend and backend types in perfect sync.

TypeSharp is a developer-first CLI tool built for teams working with ASP.NET Core backends and TypeScript frontends (Vue, Nuxt, React, Angular). Stop duplicating your models. Let TypeSharp do it.


✨ What We Build

Repository Description
typesharp The core CLI — scan C# models, output TypeScript interfaces
TypeSharp.Attributes C# attributes for fine-grained control over type generation

⚡ Quick Example

// C# — your source of truth
public class ProductDto {
    public int Id { get; set; }
    public string Name { get; set; }
    public decimal? Price { get; set; }
    public ProductCategory Category { get; set; }
}
typesharp generate --input ./Models --output ./frontend/types
// Auto-generated TypeScript
export interface ProductDto {
  id: number;
  name: string;
  price?: number;
  category: ProductCategory;
}

🚀 Features

  • ✅ Nullable type support (T?T | undefined)
  • ✅ Enum generation
  • ✅ Inheritance & base class resolution
  • ✅ Array and collection types
  • ✅ Custom naming conventions (camelCase, PascalCase)
  • ✅ Fine-grained control via [TypeSharp] attributes
  • ✅ Perfect for ASP.NET Core + Vue/Nuxt/React projects

📦 Installation

npm i install -g TypeSharp.Cli

🤝 Contributing

We welcome contributions! Check out our Contributing Guide to get started.


📍 Based in South Africa 🇿🇦

Pinned Loading

  1. typesharp typesharp Public

    TypeSharp CLI - Automatically generate TypeScript from C# models. Keep your frontend and backend types in perfect sync! Supports nullable types, enums, inheritance, arrays, and custom naming conven…

  2. TypeSharp.Attributes TypeSharp.Attributes Public

    C# attributes for controlling TypeSharp TypeScript generation — fine-tune property names, types, and visibility without touching the CLI config.

  3. .github .github Public

    Community health files, org profile, and issue templates for the TypeSharp CLI organization.

Repositories

Showing 3 of 3 repositories

People

This organization has no public members. You must be a member to see who’s a part of this organization.

Top languages

Loading…

Most used topics

Loading…