Javascript Get Value For Api Calling From Other Functions State

Javascript Get Value For Api Calling From Other Functions State