[bug]: Fails when trying to package binary imports

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

Maintainer thường phản hồi trong vòng 6 ngày

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

Đánh giá

Độ khó
5/5
Thời gian dự kiến
Hơn một tuần
Mức phù hợp với người mới
30/100
Loại issue
Lỗi
Độ rõ ràng
Khá rõ ràng
Mức độ hoạt động
Đình trệ
Công nghệ
node.js, typescript
Lĩnh vực
build-system, tooling

Hướng nghiên cứu

Reproduce the failure in a new server-feature plugin using @ngrok/ngrok, then trace the sdk-plugin watch and build entry points and how they invoke pack-up. Compare the behavior with packup.config.js and determine whether configurable bundlers or default .node binary imports is the appropriate scope; done means the package builds and watches successfully with the binary dependency.

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

Mô tả

issue: bug severity: medium
What version of @strapi/sdk-plugin are you using?

npm: 10.8.3
node: ^20
sdk: 5.2.7
browser: n/a

What's Wrong?

pack-up via sdk-plugin does not support binary imports like the one used in @ngrok/ngrok. 'sdk-pluginprovides no way to add bundlers and negates the ability to usepackup.config.jsby usingdisableConfig: falsewhen calling eitherwatchorbuild`.

To Reproduce
  1. Create a new plugin with server features
  2. Install @ngrok/ngrok which depends on an arch dependent dep with a .node binary
  3. Import this into a server file
  4. Running either watch or build will fail, as the tools only expect plaintext JS
Expected Behaviour

Allow developers to use binaries by either:

  1. Provide the ability to extend pack-up with extra bundlers
  2. Include the ability to import .node binaries by default
Ngôn ngữ chính
TypeScript
Star
24
Fork
13
Merge trung bình
5 ngày 3 giờ
Pull request đã merge (30 ngày)
5

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

  • Không có Dockerfile hay tệp Docker Compose
  • Có mẫu pull request
  • Không có 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 strapi/sdk-plugin

Tất cả issue của strapi/sdk-plugin

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.