SourceRoot documentation inconsistent

Đang mở
#28,099 0 bình luận 0 reaction 0 người được giao Xem trên GitHub

Chưa có ai nhận issue này.

Đánh giá

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

Hướng nghiên cứu

Bắt đầu với tài liệu về các tùy chọn trình biên dịch được liên kết và tài liệu tsconfig.json về thuộc tính extends, sau đó xác minh cách các đường dẫn sourceRoot được phân giải. Đối chiếu hai phần giải thích để hành vi được tài liệu hóa nhất quán, hoặc ghi rõ cơ sở đường dẫn thực tế trong tài liệu.

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

Mô tả

Docs

In the compiler options documentation is sourceRoot explained as follows:

Specifies the location where debugger should locate TypeScript files instead of source locations. Use this flag if the sources will be located at run-time in a different location than that at design-time. The location specified will be embedded in the sourceMap to direct the debugger where the source files will be located.

In the documentation of the extends property is explained that all path are relative to the file they originated in.

All relative paths found in the configuration file will be resolved relative to the configuration file they originated in.

I have understood that the path in sourceRoot is relative to the compiled files and points to the source files. sourceRoot is not relative to the configuration file it originates in. If I use a path relative to the configuration file, the source files are not found.

Expected behavior:
The documentation must be consistent or the path must be relative to the file they originated in.

Ngôn ngữ chính
Go
Star
111k
Fork
14.4k
Merge trung bình
1 ngày 15 giờ
Pull request đã merge (30 ngày)
106

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

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

Bắt đầu từ đâu

  1. Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
  2. 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.
  3. Fork repository và làm thay đổi trên một nhánh.
  4. Mở pull request có tham chiếu số hiệu của issue.

Issue khác của microsoft/TypeScript

Tất cả issue của microsoft/TypeScript

Issue tương tự

Thêm issue về Go

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.