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

fix: 🐛 fix umd bad complier for getters and setters #90

Merged
merged 1 commit into from
May 20, 2021

Conversation

NetanelBasal
Copy link
Member

Closes: #88

PR Checklist

Please check if your PR fulfills the following requirements:

  • The commit message follows our guidelines: CONTRIBUTING.md#commit
  • Tests for the changes have been added (for bug fixes / features)
  • Docs have been added / updated (for bug fixes / features)

PR Type

What kind of change does this PR introduce?

[ ] Bugfix
[ ] Feature
[ ] Code style update (formatting, local variables)
[ ] Refactoring (no functional changes, no api changes)
[ ] Build related changes
[ ] CI related changes
[ ] Documentation content changes
[ ] Other... Please describe:

What is the current behavior?

Issue Number: N/A

What is the new behavior?

Does this PR introduce a breaking change?

[ ] Yes
[ ] No

Other information

Copy link

@markwhitfeld markwhitfeld left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM.
From my comment on the issue: #88 (comment)

I think that is a good alternative approach, as I mentioned in my PR.
It does create a coupling to the knowledge that the superclass with the accessor is AbstractControl, but I think it is safe in the case of Angular. It also may have a very slight performance hit, but it would be negligible in the bigger picture.
I thought about using the Reflect.get and Reflect.set apis, but avoided them because they are not compatible with ES5.
Getting the property descriptors once using the Object apis is a good compromise.

@NetanelBasal NetanelBasal merged commit 032d401 into master May 20, 2021
@NetanelBasal NetanelBasal deleted the fix-umd branch May 20, 2021 07:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Required validator on FormControl not working in unit tests when using jest
2 participants