Skip to content

Commit

Permalink
Add missing feature in next-swc (#40550)
Browse files Browse the repository at this point in the history
`shake_exports` relies on `ecma_transforms_optimization`, otherwise this will be thrown if running tests:

```
error[E0433]: failed to resolve: could not find `optimization` in `transforms`
 --> crates/core/src/shake_exports.rs:7:23
  |
7 |     ecma::transforms::optimization::simplify::dce::{dce, Config as DCEConfig},
  |                       ^^^^^^^^^^^^ could not find `optimization` in `transforms`
```

## Bug

- [ ] Related issues linked using `fixes #number`
- [ ] Integration tests added
- [ ] Errors have helpful link attached, see `contributing.md`

## Feature

- [ ] Implements an existing feature request or RFC. Make sure the feature request has been accepted for implementation before opening a PR.
- [ ] Related issues linked using `fixes #number`
- [ ] Integration tests added
- [ ] Documentation added
- [ ] Telemetry added. In case of a feature if it's used or not.
- [ ] Errors have helpful link attached, see `contributing.md`

## Documentation / Examples

- [ ] Make sure the linting passes by running `pnpm lint`
- [ ] The examples guidelines are followed from [our contributing doc](https://github.com/vercel/next.js/blob/canary/contributing.md#adding-examples)
  • Loading branch information
shuding committed Sep 15, 2022
1 parent 57be012 commit a8e54e7
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions packages/next-swc/crates/core/Cargo.toml
Expand Up @@ -40,6 +40,7 @@ swc_core = { version = "0.23.24", features = [
"__ecma_transforms",
"ecma_transforms_react",
"ecma_transforms_typescript",
"ecma_transforms_optimization",
"ecma_parser",
"ecma_parser_typescript",
"cached",
Expand Down

0 comments on commit a8e54e7

Please sign in to comment.