Skip to content

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

@arvindpdmn

Description

@arvindpdmn

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.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions