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

Import Decimal from decimal.js rather than decimal.mjs #3165

Open
wants to merge 1 commit into
base: develop
Choose a base branch
from

Commits on Feb 24, 2024

  1. Import Decimal from decimal.js rather than decimal.mjs

    The `decimal.js` package provides the decimal.js as well as decimal.mjs files. See: https://github.com/MikeMcl/decimal.js
    
    In certain webpack configurations, the decimal.mjs file is loaded, causing the error:
    ```
    Uncaught TypeError: decimal_js__WEBPACK_IMPORTED_MODULE_0__.default.clone is not a function
        createBigNumberClass BigNumber.js:12
        assertAndCreate factory.js:35
    ```
    
    When we are more specific with this import, this error is resolved.
    nikolas committed Feb 24, 2024
    Configuration menu
    Copy the full SHA
    1bb5647 View commit details
    Browse the repository at this point in the history