I'm using mongo, tornado, and react.
from the tornado server I got my data, I sent it to the html template and then parsed it to JSON, now I want to use this variable "obj" and pass it down to my jsx file, how can I do it?
You can use the window
global variable (which is accessed from anywhere in your code).
In your tornado template you should use:
<script>
window.obj = JSON.parse(text);
</script>
And inside your jsx
file you can access that variable from the window
object:
render() {
console.log(window.obj);
}