developit / developit/microbundle

Not generating correct names for different output formats

Đang mở
#825 6 bình luận 5 reaction 0 người được giao Được @rschristian nhận Xem trên GitHub
Ngôn ngữ chính
JavaScript
Star
8.1k
Fork
358
Chỉ số merge pull request
Không có pull request nào được merge trong 30 ngày

Mô tả

I'm trying out Microbundle with https://github.com/reduxjs/redux-toolkit . For some reason, Microbundle seems to be ignoring the names that I've specified in the various `main/module/exports` fields, and is trying to reuse the the name from `main` for all output files.

Here's what I'm seeing. Currently, I've got `package.json` configured with these file names:

```js
"source": "src/index.ts",
"main": "dist/a.js",
"exports": "./dist/b.modern.js",
"module": "dist/c.module.js",
"unpkg": "dist/d.umd.js",
"types": "dist/typings.d.ts",
```

Microbundle reports this output:

```
Build "toolkit" to dist:
7.22 kB: a.js.gz
6.45 kB: a.js.br
6.06 kB: a.modern.js.gz
5.42 kB: a.modern.js.br
7.14 kB: a.module.js.gz
6.39 kB: a.module.js.br
7.31 kB: a.umd.js.gz
6.53 kB: a.umd.js.br
```

And the output files are:

```
dist/a.js
dist/a.modern.js
dist/a.module.js
dist/a.umd.js
```

Those are clearly not the file names I specified. Is there something obvious I'm missing here?

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

Chưa lập chỉ mục được hướng dẫn đóng góp cho kho mã nguồn này

Đánh giá

Issue này chưa được đánh giá.

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.