ReferenceError: Map is not defined
See original GitHub issueThe latest change has caused the SDK to cease working on my device due to the use of the ES6 Map type:
ERROR: var activeSubscriptions = new Map();
ERROR: ^
ERROR: ReferenceError: Map is not defined
at new DeviceClient (/home/root/.node_app_slot/node_modules/aws-iot-device-sdk/device/index.js:232:34)
at Object.DeviceClient [as device] (/home/root/.node_app_slot/node_modules/aws-iot-device-sdk/device/index.js:164:14)
at Object.<anonymous> (/home/root/.node_app_slot/main.js:11:21)
at Module._compile (module.js:456:26)
at Object.Module._extensions..js (module.js:474:10)
at Module.load (module.js:356:32)
at Function.Module._load (module.js:312:12)
at Function.Module.runMain (module.js:497:10)
at startup (node.js:119:16)
at node.js:935:3
Issue Analytics
- State:
- Created 8 years ago
- Comments:25 (7 by maintainers)
Top Results From Across the Web
Map() is not defined in Google Chrome - javascript
I've been searching for an answer but I'm only getting results regarding the Google maps API. I ...
Read more >Uncaught ReferenceError: Map is not defined at line #617
I added the server.bundle.js and this error showed up. Upon looking at the bundle I figured out that it came from this line, ......
Read more >[JDK-8194738] ReferenceError: "Map" is not defined
ReferenceError : "Map" is not defined ... Resolution: Not an Issue. Affects Version/s: 9.0.1. Fix Version/s: None. Component/s: core-libs. Labels:.
Read more >Uncaught ReferenceError: google is not defined | WordPress.org
Hi @shampie,. This seems a dependency issue with Google Maps, are you using the Script Center by any chance? We can add a...
Read more >TypeError: object.map is not a function in JavaScript
The "object.map is not a function" error occurs because the map method is not implemented on objects. To iterate over an object, use...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
@jdelaune, yes you can install the previous version with ‘npm install aws-iot-device-sdk@1.0.10’. That version doesn’t include any ES6 types. These will be removed from the next release. Thanks for using AWS IoT.
Try npm install aws-iot-device-sdk@1.0.10