re: Building RESTful Web APIs with Dart, Aqueduct, and PostgreSQL — Part 1 VIEW POST

FULL DISCUSSION
 

August 12, 2018

As of Dart 2: I want to clarify things that needs to be changed.

router.route('/').listen((request) async {
  return new Response.ok('Hello world')
    ..contentType = ContentType.TEXT;
});

to

    router.route('/').linkFunction((router) async {
      return Response.ok("Hello World");
    });

Although I would like to point out many things, it's better to check out in their documentation because a lot of it are deprecated.

Have a great day!

 

Thanks Vince. Will do the rounds and make the edits soon.

code of conduct - report abuse