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: Prevent webpack loading bindings when importing UTXOInput type #990

Merged

Conversation

msarcev
Copy link
Contributor

@msarcev msarcev commented Aug 3, 2023

Description of change

  • Moved UTXOInput#fromOutputId static function to lib/index.ts to be attached dynamically.

Prevents webpack loading bindings when just importing UTXOInput type.

Links to any relevant issues

Be sure to reference any related issues by adding fixes #issue_number.

Type of change

Choose a type of change, and delete any options that are not relevant.

  • Bug fix (a non-breaking change which fixes an issue)

How the change has been tested

Tested the static function manually with some outputId cases.

Change checklist

Tick the boxes that are relevant to your changes, and delete any items that are not.

  • I have followed the contribution guidelines for this project
  • I have performed a self-review of my own code
  • I have commented my code, particularly in hard-to-understand areas
  • I have made corresponding changes to the documentation
  • I have added tests that prove my fix is effective or that my feature works
  • I have checked that new and existing unit tests pass locally with my changes

Copy link

@DaughterOfMars DaughterOfMars left a comment

Choose a reason for hiding this comment

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

I don't think this is the right approach

… bindings loading when using type UTXOInput)
Copy link

@DaughterOfMars DaughterOfMars left a comment

Choose a reason for hiding this comment

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

I think this is okay?

@qrayven
Copy link
Contributor

qrayven commented Aug 8, 2023

I think this is okay?

I think It's ok because this is technically the only place we import bindings in types, so we won't need similar fixes for other types.

@Thoralf-M Thoralf-M merged commit ade9749 into iotaledger:develop Aug 8, 2023
8 checks passed
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.

5 participants