You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have tried using the module while using react-native-cli. After some time I managed to get it to work. I have however now tried to use it using Expo, and I keep getting the same error:
I have the following code:
import React, {useEffect, useState} from 'react'
import { View, Button, Text} from 'react-native';
import * as Mqtt from 'react-native-native-mqtt';
import buffer from 'buffer'
global.Buffer = buffer.Buffer;
Hello!
I have tried using the module while using react-native-cli. After some time I managed to get it to work. I have however now tried to use it using Expo, and I keep getting the same error:
I have the following code:
import React, {useEffect, useState} from 'react'
import { View, Button, Text} from 'react-native';
import * as Mqtt from 'react-native-native-mqtt';
import buffer from 'buffer'
global.Buffer = buffer.Buffer;
const Mqtt = ({client}) => {
const [error, setError] = useState('');
const [payload, setPayload] = useState('');
const [connectStatus, setConnectStatus] = useState('Disconnected');
}
export default Mqtt;
Does anyone have a tip, or experienced similar things?
The text was updated successfully, but these errors were encountered: