React-native-gifted-chat: tslib not found

Created on 7 Jun 2019  路  5Comments  路  Source: FaridSafi/react-native-gifted-chat

Issue Description

I just created new react-native project and installed gifted-chat. But I'm getting the following error while trying to run project on windows&android emulator.

error: bundling failed: Error: Unable to resolve module tslib from C:\Users\ASUS\Apps\EvdeBakim\node_modules\react-native-gifted-chat\lib\Avatar.js: Module tslib does not exist in the Haste module map

I tried already to remove node_modules and npm install again. Thanks for the great module and any help in advance.

Steps to Reproduce / Code Snippets

npm install react-native-gifted-chat --save
react-native run-android

Expected Results

Gifted Chat screen!

Additional Information

  • Nodejs version: v10.4.0
  • React version: 16.8.3
  • React Native version: 0.59.9
  • react-native-gifted-chat version: ^0.9.3
  • Platform(s) (iOS, Android, or both?): Android
  • TypeScript version: No TypeScript

Most helpful comment

Hi guys,
Sorry about that, I've just changed the TS config to not have a require dependency to tslib.
Please test the new version 0.9.4.
Thanks

All 5 comments

+1

You should run npm install --save tslib

@dnolbon thanks for the answer. It solved the issue.
Just wondering, why this wasn't an issue before and happened with latest version? is it a new dependency for the gifted-chat?

Hi guys,
Sorry about that, I've just changed the TS config to not have a require dependency to tslib.
Please test the new version 0.9.4.
Thanks

@xcarpentier thanks for quick fix.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

cassioseffrin picture cassioseffrin  路  3Comments

pentarex picture pentarex  路  3Comments

Hayko1994 picture Hayko1994  路  3Comments

radvc picture radvc  路  3Comments

inceptivetech picture inceptivetech  路  3Comments