Skip to content


Subversion checkout URL

You can clone with
Download ZIP
Fetching contributors…

Cannot retrieve contributors at this time

89 lines (55 sloc) 1.91 KB
The easiest way to write a webapp with Perl
=== ABOUT ===
That project intends to become a port of Ruby's Sinatra framework: a framework
for building web application with minimal-effort in mind.
The user should be able to define a webapp with very few lines of codes.
=== NEWS ===
Dancer's development moves very fast, to stay tuned follow
sukria on Twitter:
=== EXAMPLE ===
To create a new Dancer application, use the helper script "dancer" provided
with this distribution:
$ dancer -a mywebapp
+ mywebapp
+ mywebapp/config.yml
+ mywebapp/views
+ mywebapp/views/layouts
You have then a new Dancer application in 'mywebapp'.
Here is an example of a webapp built with Dancer:
use Dancer;
get '/' => sub {
"Hello There!"
get '/hello/:name' => sub {
"Hey ".params->{name}.", how are you?";
post '/new' => sub {
"creating new entry: ".params->{name};
When running this script, a webserver is running and ready to serve:
$ perl ./
>> Listening on
== Entering the dance floor ...
Then it's possible to access any route defined in the script:
$ curl http://localhost:1915/
Hello There!
Feel free to fork that project if you like the idea and want to add some
Dancer depends on the following modules
- HTTP::Server::Simple
- File::MimeInfo
- Template
This is a work in progress.
Dancer supports PSGI/Plack, to run a Dancer app with PSGI/Plack
=== WEBSITE ===
For more details about the project, checkout the official website:
Jump to Line
Something went wrong with that request. Please try again.