originalgremlin / react-native-browser-builtins

Browser altenatives to built-in node.js modules for React Native.
MIT License
6 stars 3 forks source link

[React Native App] Unknown named module: 'stream' #2

Open arvindpdmn opened 7 years ago

arvindpdmn commented 7 years ago

I started by updating package.json with "react-native-browser-builtins": "^2.0.3" and then I ran npm install.

I am also using another module called losant-mqtt, which I think was originally written to run in a Node.js server environment. Before using react-native-browser-builtins, I used to get errors for missing modules util, events and buffer. These errors are now gone.

There's one file in losant-mqtt that has the following statement: var Stream = require('stream').Stream

This is still giving an error, although react-native-browser-builtins is supposed to include this. Please let me know how to solve this.

arvindpdmn commented 7 years ago

I notice that I don't have stream in my installation. I have the following:

stream-buffers/ 
stream-counter/  
stream-combiner/  
stream-shift/
MattFoley commented 7 years ago

Did you ever resolve this issue?