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

trying to use matrix-js-sdk #20872

Closed
3 tasks
moeinrahimi opened this issue Aug 27, 2018 · 1 comment
Closed
3 tasks

trying to use matrix-js-sdk #20872

moeinrahimi opened this issue Aug 27, 2018 · 1 comment
Labels
Resolution: Locked This issue was locked by the bot.

Comments

@moeinrahimi
Copy link

moeinrahimi commented Aug 27, 2018

Environment

React Native Environment Info:
System:
OS: Windows 10
CPU: x64 Intel(R) Core(TM) i5-6500 CPU @ 3.20GHz
Memory: 962.29 MB / 7.86 GB
Binaries:
Yarn: 1.1.0 - C:\Program Files (x86)\Yarn\bin\yarn.CMD
npm: 5.3.0 - C:\Program Files\nodejs\npm.CMD
Watchman: 4.9.4 - C:\watchman\watchman.EXE
IDEs:
Android Studio: Version 2.2.0.0 AI-145.3276617

Description

so basically i'm trying to use a library named matrix-js-sdk , it is working fine on another project built react itself , but on react-native when i require the library i get below error message , the mentioned issue page in error message didin't help . and also if it helps this is my issue page on matrix-js-sdk repo
matrix-org/matrix-js-sdk#657

error: bundling failed: Error: Unable to resolve module events from
F:\projec ts\myApp\node_modules\matrix-js-sdk\lib\models\event.js:
Module events does n ot exist in the Haste module map

This might be related to #4968
To resolve try the following:

Clear watchman watches: watchman watch-del-all.
Delete the node_modules folder: rm -rf node_modules && npm install.
Reset Metro Bundler cache: rm -rf /tmp/metro-bundler-cache-* or npm star t -- --reset-cache. 4. Remove haste cache: rm -rf /tmp/haste-map-react-native -packager-*.
at ModuleResolver.resolveDependency (F:\projects\myApp\node_modules\metro\sr c\node-haste\DependencyGraph\ModuleResolution.js:161:1460)
at ResolutionRequest.resolveDependency (F:\projects\myApp\node_modules\metro \src\node-haste\DependencyGraph\ResolutionRequest.js:91:16)
at DependencyGraph.resolveDependency (F:\projects\myApp\node_modules\metro\s rc\node-haste\DependencyGraph.js:272:4579)
at dependencies.map.relativePath (F:\projects\myApp\node_modules\metro\src\D eltaBundler\traverseDependencies.js:376:19)
at Array.map ()
at resolveDependencies (F:\projects\myApp\node_modules\metro\src\DeltaBundle r\traverseDependencies.js:374:16)
at F:\projects\myApp\node_modules\metro\src\DeltaBundler\traverseDependencie s.js:212:33
at Generator.next ()
at step (F:\projects\myApp\node_modules\metro\src\DeltaBundler\traverseDepen dencies.js:297:313)
at F:\projects\myApp\node_modules\metro\src\DeltaBundler\traverseDependencie s.js:297:473

Reproducible Demo

Let us know how to reproduce the issue. Include a code sample, share a project, or share an app that reproduces the issue using https://snack.expo.io/. Please follow the guidelines for providing a MCVE: https://stackoverflow.com/help/mcve

@moeinrahimi moeinrahimi changed the title trying to require a module trying to require a matrix-js-sdk Aug 27, 2018
@moeinrahimi moeinrahimi changed the title trying to require a matrix-js-sdk trying to use matrix-js-sdk Aug 27, 2018
@dulmandakh
Copy link
Contributor

Please check if matrix-js supports React Native, and refer to its documentation.

@facebook facebook locked as resolved and limited conversation to collaborators Aug 30, 2019
@react-native-bot react-native-bot added the Resolution: Locked This issue was locked by the bot. label Aug 30, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Resolution: Locked This issue was locked by the bot.
Projects
None yet
Development

No branches or pull requests

3 participants