LoginSignup
0

More than 5 years have passed since last update.

React Nativeでnode moduleを使おうとしたらエラーでた。

Posted at

タイトルの通りなんだけどエラーでた。
モジュールの解決に失敗している様子。

原因

対処法的なの一通りしたところで気がついた。

Node.jsのeventsモジュールが無くてエラー出てることに・・・
実はエラー文にちゃんと書いてあった。

React NativeはJSのエンジンとしてJavaScriptCoreを使っているので、Nodeのnativeなモジュールを使っているようなモジュールは読み込めないのだった。

反省

思い込みカッコ悪い。

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0