Skip to content

Commit

Permalink
make differences between route generators a little more obvious
Browse files Browse the repository at this point in the history
  • Loading branch information
kraih committed Mar 18, 2014
1 parent 73a764a commit e2de323
Show file tree
Hide file tree
Showing 3 changed files with 17 additions and 17 deletions.
2 changes: 1 addition & 1 deletion Changes
@@ -1,5 +1,5 @@

4.91 2014-03-17
4.91 2014-03-18

4.90 2014-03-16
- Removed deprecated to_rel method from Mojo::URL.
Expand Down
16 changes: 8 additions & 8 deletions lib/Mojolicious/Lite.pm
Expand Up @@ -1001,7 +1001,7 @@ automatically exported.
=head2 any
my $route = any '/:foo' => sub {...};
my $route = any '/:foo' => [foo => qr/\w+/] => sub {...};
my $route = any [qw(GET POST)] => '/:foo' => sub {...};
Generate route with L<Mojolicious::Routes::Route/"any">, matching any of the
Expand All @@ -1016,14 +1016,14 @@ The L<Mojolicious::Lite> application.
=head2 del
my $route = del '/:foo' => sub {...};
my $route = del '/:foo' => [foo => qr/\w+/] => sub {...};
Generate route with L<Mojolicious::Routes::Route/"delete">, matching only
C<DELETE> requests. See also the tutorial above for more argument variations.
=head2 get
my $route = get '/:foo' => sub {...};
my $route = get '/:foo' => [foo => qr/\w+/] => sub {...};
Generate route with L<Mojolicious::Routes::Route/"get">, matching only C<GET>
requests. See also the tutorial above for more argument variations.
Expand All @@ -1048,15 +1048,15 @@ Share code with L<Mojolicious/"hook">.
=head2 options
my $route = options '/:foo' => sub {...};
my $route = options '/:foo' => [foo => qr/\w+/] => sub {...};
Generate route with L<Mojolicious::Routes::Route/"options">, matching only
C<OPTIONS> requests. See also the tutorial above for more argument
variations.
=head2 patch
my $route = patch '/:foo' => sub {...};
my $route = patch '/:foo' => [foo => qr/\w+/] => sub {...};
Generate route with L<Mojolicious::Routes::Route/"patch">, matching only
C<PATCH> requests. See also the tutorial above for more argument variations.
Expand All @@ -1069,14 +1069,14 @@ Load a plugin with L<Mojolicious/"plugin">.
=head2 post
my $route = post '/:foo' => sub {...};
my $route = post '/:foo' => [foo => qr/\w+/] => sub {...};
Generate route with L<Mojolicious::Routes::Route/"post">, matching only
C<POST> requests. See also the tutorial above for more argument variations.
=head2 put
my $route = put '/:foo' => sub {...};
my $route = put '/:foo' => [foo => qr/\w+/] => sub {...};
Generate route with L<Mojolicious::Routes::Route/"put">, matching only C<PUT>
requests. See also the tutorial above for more argument variations.
Expand All @@ -1092,7 +1092,7 @@ more argument variations.
=head2 websocket
my $route = websocket '/:foo' => sub {...};
my $route = websocket '/:foo' => [foo => qr/\w+/] => sub {...};
Generate route with L<Mojolicious::Routes::Route/"websocket">, matching only
WebSocket handshakes. See also the tutorial above for more argument
Expand Down
16 changes: 8 additions & 8 deletions lib/Mojolicious/Routes/Route.pm
Expand Up @@ -318,7 +318,7 @@ current parent if necessary.
=head2 any
my $route = $r->any('/:foo' => sub {...});
my $route = $r->any('/:foo' => [foo => qr/\w+/] => sub {...});
my $route = $r->any([qw(GET POST)] => '/:foo' => sub {...});
Generate route matching any of the listed HTTP request methods or all. See
Expand All @@ -341,7 +341,7 @@ Generate bridge route with optional pattern and restrictive placeholders.
=head2 delete
my $route = $r->delete('/:foo' => sub {...});
my $route = $r->delete('/:foo' => [foo => qr/\w+/] => sub {...});
Generate route matching only C<DELETE> requests. See also the
L<Mojolicious::Lite> tutorial for more argument variations.
Expand Down Expand Up @@ -369,7 +369,7 @@ generated ones.
=head2 get
my $route = $r->get('/:foo' => sub {...});
my $route = $r->get('/:foo' => [foo => qr/\w+/] => sub {...});
Generate route matching only C<GET> requests. See also the
L<Mojolicious::Lite> tutorial for more argument variations.
Expand Down Expand Up @@ -427,7 +427,7 @@ if necessary.
=head2 options
my $route = $r->options('/:foo' => sub {...});
my $route = $r->options('/:foo' => [foo => qr/\w+/] => sub {...});
Generate route matching only C<OPTIONS> requests. See also the
L<Mojolicious::Lite> tutorial for more argument variations.
Expand Down Expand Up @@ -456,7 +456,7 @@ Parse pattern.
=head2 patch
my $route = $r->patch('/:foo' => sub {...});
my $route = $r->patch('/:foo' => [foo => qr/\w+/] => sub {...});
Generate route matching only C<PATCH> requests. See also the
L<Mojolicious::Lite> tutorial for more argument variations.
Expand All @@ -465,7 +465,7 @@ L<Mojolicious::Lite> tutorial for more argument variations.
=head2 post
my $route = $r->post('/:foo' => sub {...});
my $route = $r->post('/:foo' => [foo => qr/\w+/] => sub {...});
Generate route matching only C<POST> requests. See also the
L<Mojolicious::Lite> tutorial for more argument variations.
Expand All @@ -474,7 +474,7 @@ L<Mojolicious::Lite> tutorial for more argument variations.
=head2 put
my $route = $r->put('/:foo' => sub {...});
my $route = $r->put('/:foo' => [foo => qr/\w+/] => sub {...});
Generate route matching only C<PUT> requests. See also the
L<Mojolicious::Lite> tutorial for more argument variations.
Expand Down Expand Up @@ -567,7 +567,7 @@ restrictions.
=head2 websocket
my $ws = $r->websocket('/:foo' => sub {...});
my $route = $r->websocket('/:foo' => [foo => qr/\w+/] => sub {...});
Generate route matching only WebSocket handshakes. See also the
L<Mojolicious::Lite> tutorial for more argument variations.
Expand Down

0 comments on commit e2de323

Please sign in to comment.