I am trying to use aws-iot-device-sdk
js sdk in our reactjs application. I am getting below errors..
ERROR in ./~/aws-iot-device-sdk/common/lib/tls-reader.js
Module not found: Error: Cannot resolve module 'fs' in /Users/xxxxx/react/aws-iot/node_modules/aws-iot-device-sdk/common/lib
@ ./~/aws-iot-device-sdk/common/lib/tls-reader.js 17:16-29
ERROR in ./~/aws-iot-device-sdk/device/lib/tls.js
Module not found: Error: Cannot resolve module 'tls' in /Users/xxxx/react/aws-iot/node_modules/aws-iot-device-sdk/device/lib
@ ./~/aws-iot-device-sdk/device/lib/tls.js 17:10-24
How to get rid of these errors?
ERROR in ./~/aws-iot-device-sdk/~/mqtt/mqtt.js Module parse failed: /Users/xxxx/react/aws-iot/node_modules/aws-iot-device-sdk/node_modules/mqtt/mqtt.js Unexpected character '#' (1:0) You may need an appropriate loader to handle this file type. SyntaxError: Unexpected character '#' (1:0)
– Brouhaha