Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我如何console.error(foo);在 Dart 中做到这一点?
console.error(foo);
该print()方法非常接近,但这并不是我想要的。我希望有错误通知和图标以及堆栈跟踪。
print()
在 Dart 中做起来其实很简单:
import 'dart:html'; main() { window.console.error('Something bad occurred'); }