How can i build with bignumber.js?

i use cocos creator 2.4.13
and import bignumber.js 9.1.2

i can play in editor but build fail like screenshot…

help please

try to import it as a plugin.

  1. select the bignumber.js in editor
  2. check the ‘load as plugin’ option

i installed bignumber.js from npm
how can i import ?


you can try 。import { BigNumber } from “…/node_modules/bignumber.js/bignumber.mjs”;