Skip to content

Commit

Permalink
small documentation tweaks
Browse files Browse the repository at this point in the history
  • Loading branch information
kraih committed Mar 30, 2012
1 parent 6f6aca3 commit b351a12
Show file tree
Hide file tree
Showing 6 changed files with 19 additions and 12 deletions.
3 changes: 3 additions & 0 deletions Changes
@@ -1,5 +1,8 @@
This file documents the revision history for Perl extension Mojolicious.

2.71 2012-03-31
- Improved documentation.

2.70 2012-03-30
- Improved speed of version command by switching to the MetaCPAN API.
- Improved all bundled TLS test certificates to expire at the same time.
Expand Down
2 changes: 1 addition & 1 deletion lib/Mojolicious.pm
Expand Up @@ -33,7 +33,7 @@ has static => sub { Mojolicious::Static->new };
has types => sub { Mojolicious::Types->new };

our $CODENAME = 'Leaf Fluttering In Wind';
our $VERSION = '2.70';
our $VERSION = '2.71';

# "These old doomsday devices are dangerously unstable.
# I'll rest easier not knowing where they are."
Expand Down
8 changes: 4 additions & 4 deletions lib/Mojolicious/Controller.pm
Expand Up @@ -621,8 +621,8 @@ implements the following new ones.
my $app = $c->app;
$c = $c->app(Mojolicious->new);
A reference back to the L<Mojolicious> application that dispatched to this
controller, defaults to a L<Mojolicious> object.
A reference back to the application that dispatched to this controller,
defaults to a L<Mojolicious> object.
# Use application logger
$c->app->log->debug('Hello Mojo!');
Expand Down Expand Up @@ -824,8 +824,8 @@ Same as C<render> but returns the rendered result.
my $success = $c->render_static('images/logo.png');
my $success = $c->render_static('../lib/MyApp.pm');
Render a static file using L<Mojolicious::Static>, relative to the C<public>
directories of your application.
Render a static file using L<Mojolicious::Static/"serve">, usually from the
C<public> directory or C<DATA> section of your application.
=head2 C<render_text>
Expand Down
8 changes: 6 additions & 2 deletions lib/Mojolicious/Renderer.pm
Expand Up @@ -386,8 +386,12 @@ Get a DATA template by name, usually used by handlers.
=head2 C<render>
my ($output, $type) = $renderer->render($c);
my ($output, $type) = $renderer->render($c, $args);
my ($output, $type) = $renderer->render(Mojolicious::Controller->new);
my ($output, $type) = $renderer->render(Mojolicious::Controller->new, {
template => 'foo/bar',
format => 'html',
handler => 'epl'
});
Render output through one of the Mojo renderers. This renderer requires some
configuration, at the very least you will need to have a default C<format>
Expand Down
4 changes: 2 additions & 2 deletions lib/Mojolicious/Sessions.pm
Expand Up @@ -151,13 +151,13 @@ implements the following ones.
=head2 C<load>
$session->load($c);
$session->load(Mojolicious::Controller->new);
Load session data from signed cookie.
=head2 C<store>
$session->store($c);
$session->store(Mojolicious::Controller->new);
Store session data in signed cookie.
Expand Down
6 changes: 3 additions & 3 deletions lib/Mojolicious/Static.pm
Expand Up @@ -214,15 +214,15 @@ and implements the following ones.
=head2 C<dispatch>
my $success = $static->dispatch($c);
my $success = $static->dispatch(Mojolicious::Controller->new);
Dispatch a L<Mojolicious::Controller> object.
=head2 C<serve>
my $success = $static->serve($c, 'foo/bar.html');
my $success = $static->serve(Mojolicious::Controller->new, 'foo/bar.html');
Serve a specific file, relative to C<paths>.
Serve a specific file, relative to C<paths> or from C<classes>.
=head1 SEE ALSO
Expand Down

0 comments on commit b351a12

Please sign in to comment.