andywer / andywer/squid

Support for branded types in schema

Đang mở
#34 0 bình luận 0 reaction 0 người được giao Xem trên GitHub
enhancement
Ngôn ngữ chính
TypeScript
Star
157
Fork
7
Chỉ số merge pull request
Không có pull request nào được merge trong 30 ngày

Mô tả

We use brands extensively in our code to make it easy to distinguish between different types of integers. For example:
```
type Brand = K & { __brand: T };
export type CommunityId = Brand;
export type UserId = Brand;
```

It would be great if I could define this in my schema so that the columns in query results have the right type instead of having to be converted.

Thanks!

Hướng dẫn đóng góp

Chưa lập chỉ mục được hướng dẫn đóng góp cho kho mã nguồn này

Đánh giá

Issue này chưa được đánh giá.

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.