developit / developit/microbundle

Types haven't been bundled by microbundle

Open
#1,084 2 comments 0 reactions 0 assignees Claimed by @rschristian View on GitHub
Dominant language
JavaScript
Stars
8.1k
Forks
358
PR merge metrics
No merged PRs in 30d

Description

Microbundle ignores `*.ts` files if they contain only types. Example of the file: https://github.com/XaveScor/signal-components/blob/dff96fd7151db5aae7421059836794a7880c2649/src/types.ts.

### Reproduction:
```
git clone https://github.com/XaveScor/signal-components
git checkout tags/v0.11.0
pnpm install
pnpm build
```

### Expected Result:
`types.d.ts` is included in the `./dist` directory.

### Actual Result:
`types.d.ts` does not exist. Types are broken because we have `./types` imports, but the file is missing.

Contributor guide

No contributing guide indexed for this repository

Research direction

Start with the linked signal-components example at src/types.ts and reproduce the issue by checking out tag v0.11.0, running pnpm install, and then pnpm build. Inspect the generated ./dist output and verify that types.d.ts is present and that ./types imports resolve; compare the result with the open linked pull request.

Written by the indexing model from the issue text.

Assessment

Tech stack
rollup, typescript
Domain
build-system, tooling
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.