Reputation: 2506
I need to parse a JavaScript file that exists on the Web with Node.
The file looks as follows:
var obj = {"data": [{"property1":40}]}
Is there any way I can download the file as a string, and parse it so it to an object? i.e. so that after I have parsed the file I can do:
var data = obj.data;
Upvotes: 2
Views: 647