Nuxt 4 module author: Component slot prop types missing.
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
- 38/100
- Loại issue
- Lỗi
- Độ rõ ràng
- Khá rõ ràng
- Mức độ hoạt động
- Đình trệ
- Công nghệ
- nuxtjs, typescript
- Lĩnh vực
- build-system, tooling
Hướng nghiên cứu
Bắt đầu với bản tái hiện được liên kết và chạy npm run dev:prepare && npm run prepack. Kiểm tra các tệp được tạo dist/runtime/components/NavigationComponent.d.vue.ts và NavigationComponent.vue.d.ts, so sánh prop data của slot content với NavigationItem[] từ NavigationComponent.vue. Được xem là hoàn tất khi các khai báo được tạo giữ nguyên kiểu của prop slot thay vì phát ra any.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Mô tả
Environment
- Operating System: Darwin
- Node Version: v22.14.0
- Nuxt Version: 4.2.1
- CLI Version: 3.30.0
- Nitro Version: 2.12.9
- Package Manager: [email protected]
- Builder: -
- User Config: -
- Runtime Modules: -
- Build Modules: -
Reproduction
Public github repo:
https://github.com/juanpscotto/nuxt-4-module-starter-types-issue
Stackblitz:
In stackblitz wait until the project is setup. Or run this command npm run dev:prepare && npm run prepack if running locally.
Once it has finished check the dist/runtime/components/NavigationComponent.d.vue.ts file, the slot type is missing.
Additional context
There is one component NavigationComponent that has a named slot content with a data prop array of type NavigationItem[]. That type is carried over as any in both NavigationComponent.d.vue.ts and NavigationComponent.vue.d.ts files
NavigationComponent.vue:
NavigationComponent.d.vue.ts
Describe the bug
The slot props types are not being carried over to the generated .ts files of the .vue components. I expect the type of the data props to be recognized.
Logs
- Ngôn ngữ chính
- TypeScript
- Star
- 277
- Fork
- 36
- Merge trung bình
- 2 giờ 46 phút
- Pull request đã merge (30 ngày)
- 2
Chuẩn bị môi trường
- Không có Dockerfile hay tệp Docker Compose
- Không có mẫu pull request
- Đọc 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.
Issue khác của nuxt/module-builder
-
Độ khó 3/5 1-2 ngày Mức phù hợp với người mới 68/100
nuxt/module-builder#801 ·
-
enhancement
Độ khó 3/5 1-2 ngày Mức phù hợp với người mới 48/100
nuxt/module-builder#764 ·
-
Độ khó 3/5 1-2 ngày Mức phù hợp với người mới 45/100
nuxt/module-builder#754 ·
-
Conflict between folder structure in readme (src/runtime) and TypeScript config (src/module/runtime)Có thể đã có người làm @dword-design đã nhận 137 ngày trước. Đang mở
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 45/100
nuxt/module-builder#749 ·
-
Tsdown/obuild migrationCó thể làm lại được Pull request cho issue này đã bị đóng mà không được merge. Đang mở
Độ khó 5/5 Hơn một tuần Mức phù hợp với người mới 25/100
nuxt/module-builder#726 · 1 bình luận · 1 reaction ·
Tất cả issue của nuxt/module-builder
Issue tương tự
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 76/100
radix-ui/primitives#4228 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 66/100
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 70/100
SignalK/freeboard-sk#1093 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 76/100
Maintainer thường phản hồi trong vòng 1 ngày
-
[测试] 等待仓库加载后再记录多仓库排序基线Có thể đã có người làm @myot233 đã nhận hôm nay. Đang mở
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 84/100
Maintainer thường phản hồi trong vòng 1 ngày