Because your request is asynchron and your JSNI code does not wait at the
$wnd.$.get call. Your method will complete immediately and return nothing
as it does not have a return statement.
You would need to change your getData() method to something like:
public native void getData(String trainer
I have the following method. If I call this method I always get a null or
empty string, however the console.log(data) shows that indeed "data" has
something in it. Why is data not being returned?
public native String getData(String trainerName)/*-{
var self = this;
$wnd.$.get( "http://te