Skip to content

pombredanne/routr-dsl

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 

Repository files navigation

Docstring based DSL for routr.

""" My micro web app.

It handle the following routes

  GET /hello?message=str&[format=str]
  GET /messages?[limit=int]&[offset=int]

"""

def get_hello(message=None, format=None):
    return Response(...)

def get_messages(id, limit=10, offset=0):
    return Response(...)

if __name__ == '__main__':
    from routrdsl import parse
    routes = parse(__doc__, globals())

About

Docstring based DSL for routr

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published