You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
feat(core): add external option to mutator config (orval-labs#2735)
* feat(core): add external option to mutator config
Add support for esbuild's `external` option in mutator configuration.
This allows users to exclude specific modules or patterns from bundling
during mutator parsing.
Use case: Mutators that import HTTP clients from larger codebases often
have transitive dependencies on non-JS assets (scss, css, images).
Esbuild cannot bundle these, causing silent failures. With `external`,
users can skip problematic imports:
```js
mutator: {
path: './api-mutator.ts',
name: 'apiMutator',
external: ['*.scss', '*.css'],
}
```
The user-provided patterns are merged with the existing `['*']` default
that externalizes bare module imports.
* Update packages/core/src/generators/mutator-info.ts
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
---------
Co-authored-by: Melloware <mellowaredev@gmail.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
0 commit comments