[CHORE]: remove `scatter` trace from custom bundle
Chưa có ai nhận issue này.
- Ngôn ngữ chính
- JavaScript
- Star
- 18.3k
- Fork
- 2k
- Merge trung bình
- 2 ngày 12 giờ
- Pull request đã merge (30 ngày)
- 28
Mô tả
Quoted from https://github.com/plotly/plotly.js/blob/main/CUSTOM_BUNDLE.md:
Please note that the scatter trace is currently included in all bundles and cannot be removed. This behaviour may change in the future, so we recommend that you explicitly include scatter anyway if you need it in your bundle.
There was previously an attempt to make scatter optional in #5535, but that PR was closed without being merged.
Since plotly.js is relatively large even when using a custom bundle, being able to exclude unused traces such as scatter would help further reduce the bundle size.
I'm not sure how much bundle size reduction this would result in, since scattergl, scatterternary and some other traces reuse parts of the scatter implementation. Still, it seems useful for custom bundles to avoid including trace modules that are not explicitly requested where possible.
Would it be worth to re-consider this optimization?
If scatter still needs to be included for architectural reasons, it may be worth updating the documentation? Since the PR is closed.
Hướng dẫn đóng góp
Bắt đầu từ đâu
- Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
- Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
- Fork repository và làm thay đổi trên một nhánh.
- Mở pull request có tham chiếu số hiệu của issue.
Hướng nghiên cứu
Bắt đầu với CUSTOM_BUNDLE.md và cuộc thảo luận đã đóng #5535 để hiểu ràng buộc hiện tại khi bundling các trace scatter. Kiểm tra xem các bundle tùy chỉnh có thể loại trừ scatter mà không làm hỏng scattergl, scatterternary hoặc các trace phụ thuộc khác hay không. Hoàn thành có nghĩa là scatter không được yêu cầu được loại trừ an toàn, hoặc tài liệu giải thích rõ ràng lý do nó phải tiếp tục được включed.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Đánh giá
- Công nghệ
- javascript
- Lĩnh vực
- build-system, data-visualization
- Loại issue
- Tính năng
- Độ khó
- 5/5
- Thời gian dự kiến
- Hơn một tuần
- Mức độ hoạt động
- Sôi nổi
- Độ rõ ràng
- Cần làm rõ
- Mức phù hợp với người mới
- 38/100