Hacktoberfest 2026: những issue maintainer đã đánh dấu cho tháng Mười, đang mở và phù hợp người mới. Xem issue Hacktoberfest

BUG: `multi DOCUMENT_PATH` not inferred correctly.

Đang mở
#89 2 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ó
4/5
Thời gian dự kiến
3-5 ngày
Mức phù hợp với người mới
35/100
Loại issue
Lỗi
Độ rõ ràng
Khá rõ ràng
Mức độ hoạt động
Đình trệ
Công nghệ
nextjs, typescript, webpack
Lĩnh vực
tooling

Hướng nghiên cứu

Bắt đầu bằng cách kiểm tra parser của bundle xử lý mục nhập multi NAME như thế nào và so sánh với mã nguồn module sau đây được hiển thị cho next/dist/pages/_document.js. Xác định cách các tên nguồn khác nhau cần được giữ nguyên, sau đó thêm các bài kiểm thử hồi quy bao quát dạng bundle này và xác minh rằng báo cáo không còn coi cả hai nguồn là cùng một tệp nữa.

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

Mô tả

bug

If we produce up with a bundle like:

/***/ 61:
/*!*******************************************************************************!*\
  !*** multi /PATH/TO/my-app/node_modules/next/dist/pages/_document.js ***!
  \*******************************************************************************/
/*! no static exports found */
/*! all exports used */
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */
/***/ (function(module, exports, __webpack_require__) {

module.exports = __webpack_require__(/*! /PATH/TO/my-app/node_modules/next/dist/pages/_document.js */62);


/***/ }),

/***/ 62:
/*!*************************************************************************!*\
  !*** /PATH/TO/my-app/node_modules/next/dist/pages/_document.js ***!
  \*************************************************************************/
/*! no static exports found */
/*! all exports used */
/*! ModuleConcatenation bailout: Module is not an ECMAScript module */
/***/ (function(module, exports, __webpack_require__) {

module.exports = __webpack_require__(/*! next/document */ 63)

We get the plugin report of:

## static/HASH/pages/_document.js
next (Found 1 resolved, 1 installed. Latest version 7.0.0.)
  7.0.0
    ~/next
      * Dependency graph
        [email protected] -> next@^7.0.0
      * Duplicated files in static/HASH/pages/_document.js
        next/dist/pages/_document.js (S, 42)

The issue: This is because the different sources:

  • multi /PATH/TO/my-app/node_modules/next/dist/pages/_document.js
  • /PATH/TO/my-app/node_modules/next/dist/pages/_document.js

both resolve to a short name of next/dist/pages/_document.js

Task

  • Dig into what multi NAME really means.
  • See if there are other things like multi that may occur?
  • Deal with the naming issue. (Maybe preserve multi?)
  • Add regression tests.
Ngôn ngữ chính
TypeScript
Star
590
Fork
20
Chỉ số merge pull request
Không có pull request nào được merge trong 30 ngày

Chuẩn bị môi trường

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 FormidableLabs/inspectpack

Tất cả issue của FormidableLabs/inspectpack

Issue tương tự

Thêm issue về TypeScript

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.