FutureBuilder返回null,即使我能够从 杰森。
这是我在FutureBuilder的将来提供的功能
function* fetchMovies({ page }: FetchMoviesAction) {
yield put({ type: MoviesTypes.ADD_MOVIES, movies: [] }); // good
yield put({ type: 'BAD_TYPE' }); // good
}
function* watchFetchMovies() {
yield takeEvery(MoviesTypes.FETCH_MOVIES, fetchMovies);
}
这是FutureBuilder小部件
Future<Map> setVarsHome() async {
resultJson = await requestHomeAPI(context);
print("RESULTJSON");
print(resultJson);
return resultJson;
}