duplicated helpers
- Dominant language
- JavaScript
- Stars
- 874
- Forks
- 62
- PR merge metrics
- No merged PRs in 30d
Description
https://github.com/bublejs/buble/blob/ecc42f5685810a966bd53b77866028f5322ac7ac/src/index.js#L95
Each run a new Program object is created and causes helpers like `objectWithoutProperties` to be duplicated. This is the case when using the rollup plugin where each transforms will run the transform method.
https://github.com/bublejs/buble/blob/ecc42f5685810a966bd53b77866028f5322ac7ac/src/program/Program.js#L28
when this is `null`, the helper will be injected, this will always be null when we run transform. Is there a way to reuse it?
https://github.com/bublejs/buble/blob/ecc42f5685810a966bd53b77866028f5322ac7ac/src/program/Program.js#L63-L73
Contributor guide
No contributing guide indexed for this repository
Research direction
Start in src/index.js around line 95 and src/program/Program.js around lines 28 and 63-73. Trace how each transform creates a Program and injects helpers, then reproduce the Rollup-plugin case; done means repeated transforms no longer emit duplicate helpers such as objectWithoutProperties.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript
- Domain
- build-system, compilers
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 38/100