We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
相同的dart code。在js的 async function中使用await 是可以的 但是在js的外部 使用 var tmp=await http("https://www.baidu.com"); 会报错 SyntaxError: expecting ';' at <eval>:228
var tmp=await http("https://www.baidu.com");
SyntaxError: expecting ';' at <eval>:228
The text was updated successfully, but these errors were encountered:
本身是同步的,会直接返回结果,如果要await可以包一层匿名函数:
(async () { var tmp = await http("https://www.baidu.com"); })();
这样在dart里面收到的是Future
Future
Sorry, something went wrong.
No branches or pull requests
相同的dart code。在js的 async function中使用await 是可以的
但是在js的外部 使用
var tmp=await http("https://www.baidu.com");
会报错
SyntaxError: expecting ';' at <eval>:228
The text was updated successfully, but these errors were encountered: