viclafouch / mui-tel-input

📌 A phone number input designed for MUI (Material ui) V6 built with libphonenumber-js
https://viclafouch.github.io/mui-tel-input
MIT License
171 stars 67 forks source link

SyntaxError: Cannot use import statement outside a module mui-tel-input React Typescript Jest #153

Closed shajjhusein closed 1 month ago

shajjhusein commented 2 months ago

I see the below issue while run npm run test whi using the library mui-tel-input . arelady i have added transform: { '^.+\\.(ts|tsx)$': [ 'ts-jest', { tsconfig: 'tsconfig.test.json', isolatedModules: true, }, ], '\\.js$': '<rootDir>/node_modules/babel-jest', '^.+\\.es\\.js$': '<rootDir>/node_modules/babel-jest', }, transformIgnorePatterns: ['node_modules/(?!(mui-tel-input)/)'], any recomndations ?? below is my env

image
viclafouch commented 2 months ago

Did you follow all the recommendations ?