Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[babel-plugin] Add an option to disable transforming Domain methods #1052

Open
kireevmp opened this issue Feb 27, 2024 · 1 comment · May be fixed by #1059
Open

[babel-plugin] Add an option to disable transforming Domain methods #1052

kireevmp opened this issue Feb 27, 2024 · 1 comment · May be fixed by #1059
Labels
effector/babel-plugin babel plugin enhancement New feature or request RFC Request for Comments
Milestone

Comments

@kireevmp
Copy link
Contributor

Proposal

Add a new option transformLegacyDomainMethods to effector/babel-plugin that allows users to disable transforming unit creator methods on Domain.

  • Defaults to true, keeping the current behavior intact (backward-compatible change).
  • When disabled, this option should take priority over the current domainMethods option, ensuring no domain methods are transformed.

This should simplify the configuration for users who already need domainMethods option as a hack, and assist in migrating to the new Domain API #763.

Use case

This change can help resolve broken AST transforms, where other libraries/code use the same function names as Domain.

Issues:

Related work

SWC Plugin implementation: kireevmp/effector-swc-plugin#14
Domain unit creators deprecation issue: #1051

@kireevmp kireevmp added the RFC Request for Comments label Feb 27, 2024
@zerobias zerobias added enhancement New feature or request effector/babel-plugin babel plugin labels Mar 14, 2024
@zerobias
Copy link
Member

Good idea 👍

@zerobias zerobias added this to the effector 24 milestone May 29, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
effector/babel-plugin babel plugin enhancement New feature or request RFC Request for Comments
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants