Scorpiion / vane

Server-side framework for Dart/Dartlang with a built-in middleware system.
BSD 3-Clause "New" or "Revised" License
59 stars 11 forks source link

Add support to other basic types than String in handler arguments #11

Open Scorpiion opened 10 years ago

Scorpiion commented 10 years ago

Today this works:

  @Route("{?max}", method: GET)
  Future templates(String max)

But this does not work:

  @Route("{?max}", method: GET)
  Future templates(int max)

We should make this work so we support other types than String.

Current workaround:

  @Route("{?max}", method: GET)
  Future templates(int max) {
    var n = int.parse(max);