docs(maps): Describe how to get map instance from within component.ts to input to MapMarker, InfoWindow
- 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
Currently the example docs rely on a single use case where the user interacts with the map and a (mapClick) event grabs the map instance and passes it back to a component.ts function. If a developer wishes to decorate a map with a marker or an info window before a user interacts with it, there is no map reference to use.
It appears that standard @ViewChild methods for obtaining a dom reference do not work with the angular google-maps component. We could use a good example of how to get the map reference.
### Affected documentation page
https://github.com/angular/components/tree/master/src/google-maps/map-marker
Hướng dẫn đóng góp
Hướng nghiên cứu
Bắt đầu trong src/google-maps/map-marker và xem lại ví dụ tài liệu hiện có lấy bản đồ thông qua một sự kiện mapClick. Xác định cách lấy tham chiếu đến bản đồ từ component.ts trước khi người dùng tương tác và truyền tham chiếu đó vào MapMarker hoặc InfoWindow. Công việc được xem là hoàn tất khi tài liệu liên quan bao gồm một ví dụ hoạt động để trang trí bản đồ trước khi tương tác.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Đánh giá
- Công nghệ
- angular, typescript
- Lĩnh vực
- documentation, frontend
- Loại issue
- Tài liệu
- Độ khó
- 3/5
- Thời gian dự kiến
- 1-2 ngày
- Mức độ hoạt động
- Đình trệ
- Độ rõ ràng
- Khá rõ ràng
- Mức phù hợp với người mới
- 35/100