Where is `dart:uri` now?

dart, uri

Solution

According to this post to the Dart announcement list, `dart:uri` has been replaced with the core Uri class.

Your code translates to:

main() {
  decodeUrl("str");
}

Though it might be more instructive to write `print(Uri.decodeFull("str%20here"));`.

Problem

I want to call `decodeUrl(...)` and I was doing it as: ``` import "dart:uri"; main() { decodeUrl("str"); } ``` But now with the latest Dart-SDK, it reports: ``` Do not know how to load 'dart:uri' import 'dart:uri'; ^ ``` Seems it has been removed from the SDK. I searched a lot but still don't know where is it now. How to use the `decodeUrl(...)` with latest SDK now?

Original source