Variable No Accessible After A Firebase Call
I'm using Firebase to access to same data, but i can't use the data out of the function used to access it. How i can make a console log of the data just accessed instead of the ini
Solution 1:
whatNeed
will always contain the initial value when called outside of your callback as the console.log
will be called first since the value
event handler is asynchronous.
Post a Comment for "Variable No Accessible After A Firebase Call"