+ 10
How to get output of this code in browser?
I want this script to run on browser - https://github.com/JimmyLaurent/torrent-search-api There is a quick example given in read.me file in which a variable 'torrents' will be having all output. I am able to get the output somehow in command prompt. But I want the results to be in browser's console log or anywhere on browser. Anyone who can help?
12 Answers
+ 10
Hey Sachin Artani
Got a code snippet to examine?
the await operator is part of JS and not of the react library
+ 7
That's a node package i guess, not mean for front end react
+ 3
I dont understand relation between await operator (than is a js operator https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Operators/await ) and the link that you posted which is a nodejs package and like CalviŐ˛ suggested is for backend programming (eg. its not mean to be runned in your browser)
+ 2
Burey
If you open the readme of that repository, you will see Quick Example with 3 lines of code. That's what I want to run and get the JSON output in 'torrents' variable.
I am able to get it via node, using command- node filename.js but I want output in browser.
+ 2
I'm changing the question as it does not seems to be a reactjs question!
+ 2
Coder So many. Will discuss it someday, I am engaged into different projects nowadays! Kept it aside. đ
+ 1
You can write the node.js on glitch.com
+ 1
Coder I tried, but got errors. đ