angular / angular/components

Documentation does not explain what generics represent

Đang mở Phù hợp với người mới
#22,121 5 bình luận 0 reaction 0 người được giao Xem trên GitHub
area: dev-infra docs P2
Ngôn ngữ chính
TypeScript
Star
25k
Fork
6.8k
Merge trung bình
1 ngày 8 giờ
Pull request đã merge (30 ngày)
91

Mô tả

#### Documentation Feedback

In docs it would be helpful to have documentaion for declared TS generics.
For example, I open `MatDatepickerInputEvent` [docs](https://material.angular.io/components/datepicker/api#MatDatepickerInputEvent) and see `S` and `D` generics.
And from the docs it's unclear what these `S` and `D` represent!

I think it should be documented similar to as Java does it.
For example, a [docs](https://docs.oracle.com/en/java/javase/15/docs/api/java.base/java/util/function/Function.html) of Java's standard type `Function` contain a section

> Type Parameters:
> T - the type of the input to the function
> R - the type of the result of the function

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

Mở hướng dẫn đóng góp

Hướng nghiên cứu

Bắt đầu với mục MatDatepickerInputEvent trong tài liệu API datepicker của Angular Material và kiểm tra cách khai báo TypeScript của nó được trình bày. Ghi lại các tham số kiểu S và D đại diện cho điều gì, theo phong cách tham số kiểu được thể hiện trong tài liệu Java được liên kết. Hoàn thành khi những người mới đóng góp có thể hiểu cả hai generic từ tài liệu API.

Do mô hình lập chỉ mục viết ra từ nội dung của issue.

Đánh giá

Công nghệ
typescript
Lĩnh vực
documentation
Loại issue
Tài liệu
Độ khó
2/5
Thời gian dự kiến
1-3 giờ
Mức độ hoạt động
Ít trao đổi
Độ rõ ràng
Khá rõ ràng
Mức phù hợp với người mới
68/100

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.