Skip to content

fix(commonjs): preserve this reference in the child class#1537

Merged
shellscape merged 4 commits intorollup:masterfrom
TrickyPi:fix/rollup-5062
Jul 15, 2023
Merged

fix(commonjs): preserve this reference in the child class#1537
shellscape merged 4 commits intorollup:masterfrom
TrickyPi:fix/rollup-5062

Conversation

@TrickyPi
Copy link
Copy Markdown
Member

@TrickyPi TrickyPi commented Jul 13, 2023

Rollup Plugin Name: {name}

This PR contains:

  • bugfix
  • feature
  • refactor
  • documentation
  • other

Are tests included?

  • yes (bugfixes and features will not be merged without tests)
  • no

Breaking Changes?

  • yes (breaking changes will not be merged unless absolutely necessary)
  • no

If yes, then include "BREAKING CHANGES:" in the first commit message body, followed by a description of what is breaking.

List any relevant issue numbers:

resolves rollup/rollup#5062

Description

using Reflect.construct function to create an instance in the getAugmentedNamespace function for preserving this reference in the child class.

@TrickyPi TrickyPi requested a review from shellscape as a code owner July 13, 2023 04:07
TrickyPi and others added 2 commits July 14, 2023 15:21
Co-authored-by: Dasa Paddock <dpaddock@esri.com>
Copy link
Copy Markdown
Member

@lukastaegert lukastaegert left a comment

Choose a reason for hiding this comment

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

Awesome, great work!

@shellscape shellscape merged commit ee4feb2 into rollup:master Jul 15, 2023
@TrickyPi TrickyPi deleted the fix/rollup-5062 branch July 18, 2023 03:29
@TrickyPi TrickyPi mentioned this pull request Jul 23, 2023
9 tasks
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.

Class this is set to super() instance

4 participants