about summary refs log tree commit diff
diff options
context:
space:
mode:
authorfranck cuny <franck@lumberjaph.net>2010-02-28 12:43:25 +0100
committerfranck cuny <franck@lumberjaph.net>2010-02-28 12:43:25 +0100
commit89a3cdaeedae744b4cb2aade6904168fef43ac4c (patch)
treec9db1152e00e456e5ebe8661d17cd4d2caaecd1b
parenttest with conditionalGET, update POD (diff)
downloadplack-middleware-etag-89a3cdaeedae744b4cb2aade6904168fef43ac4c.tar.gz
POD
-rw-r--r--lib/Plack/Middleware/ETag.pm6
1 files changed, 6 insertions, 0 deletions
diff --git a/lib/Plack/Middleware/ETag.pm b/lib/Plack/Middleware/ETag.pm
index 0671ce9..0b491a7 100644
--- a/lib/Plack/Middleware/ETag.pm
+++ b/lib/Plack/Middleware/ETag.pm
@@ -51,6 +51,12 @@ Plack::Middleware::ETag - Adds automatically an ETag header.
 
 Plack::Middleware::ETag adds automatically an ETag header. You may want to use it with C<Plack::Middleware::ConditionalGET>.
 
+  my $app = builder {
+    enable "Plack::Middleware::ConditionalGET";
+    enable "Plack::Middleware::ETag";
+    sub {['200', ['Content-Type' => 'text/html'}, ['hello world']]};
+  };
+
 =head1 AUTHOR
 
 franck cuny E<lt>franck@lumberjaph.netE<gt>