Permalink
Browse files

README: prettify

  • Loading branch information...
1 parent 0ef9d93 commit 3374bc8e0f9046ddccb4fb1a40b2061fa181fb47 @andreypopp committed Apr 9, 2012
Showing with 11 additions and 2 deletions.
  1. +11 −2 README
View
13 README
@@ -1,6 +1,15 @@
routr -- lightweight request routing for WebOb
==============================================
-Docs[1] are hosted at excellent ReadTheDocs project.
+Just a small example::
-[1]: http://routr.readthedocs.org/
+ from routr import route, GET, POST
+ from routr.schema import form, String
+
+ routes = route("/users",
+ route(POST, "/", "views.create_user", guards=[form(username=String)]),
+ route(GET, "/{id:int}", "views.get_user"))
+
+Docs_ are hosted at excellent readthedocs project.
+
+.. _docs: http://routr.readthedocs.org/

0 comments on commit 3374bc8

Please sign in to comment.