raydium-io/raydium-sdk

how to solve import BN in raydium-sdk/

SyugamCan opened this issue · 0 comments

node_modules/@raydium-io/raydium-sdk/lib/types/base/util.d.ts:3:8 - error TS1259: Module '"/Users/pro/node_modules/@types/bn.js/index"' can only be default-imported using the 'esModuleInterop' flag

import BN from 'bn.js';
~~

node_modules/@types/bn.js/index.d.ts:591:1
591 export = BN;
~~~~~~~~~~~~
This module is declared with 'export =', and can only be used with a default import when using the 'esModuleInterop' flag.