Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Newer
Older
100644 37 lines (28 sloc) 0.516 kb
db6e4a1d »
2012-06-07 Make example apps work-ish
1 use lib 'lib';
2
0024c72d »
2011-01-10 Initial commit
3 use Bailador;
4
5 # simple cases
6 get '/' => sub {
7 "hello world"
d8574ae6 »
2011-12-29 Add templating support, needs Ratel
8 }
0024c72d »
2011-01-10 Initial commit
9
10 get '/about' => sub {
11 "about me"
d8574ae6 »
2011-12-29 Add templating support, needs Ratel
12 }
0024c72d »
2011-01-10 Initial commit
13
5a2b52a2 »
2011-12-27 First attack at placeholders in routes. Segfaults
14 get '/hello/:name' => sub ($name) {
15 "Hello $name!"
16 };
17
0024c72d »
2011-01-10 Initial commit
18 # regexes, as usual
19 get /foo(.+)/ => sub ($x) {
20 "regexes! I got $x"
21 }
22
23 get / '/' (.+) '-' (.+)/ => sub ($x, $y) {
24 "$x and $y"
25 }
26
27 # junctions work too
28 get any('/h', '/help', '/halp') => sub {
29 "junctions are cool"
30 }
31
d8574ae6 »
2011-12-29 Add templating support, needs Ratel
32 # templates!
33 get / ^ '/template/' (.+) $ / => sub ($x) {
34 template 'tmpl.tt', { name => $x }
35 }
36
f3b044ca »
2011-01-12 Fixed a grammar-o, sorear++
37 baile;
Something went wrong with that request. Please try again.