Examples from the official Dancer2 Cookbook.
Clone or download
manwar - Implemented Dancer2::Plugin::Paginator.
- Renamed link "List" to "Authors".
- Added new link "Books" with paginator.
- Removed similar looking characters from "Captcha".
Latest commit cd5c69f Dec 10, 2018
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
bin
environments
lib
public
t
views
Changes
MANIFEST
MANIFEST.SKIP
Makefile.PL
README
bookstore.db
bookstore.sql
config.yml
cpan.sql
populate_database.pl

README

Dancer2 Cookbook
----------------

Example 1: Bookstore

INSTALL:

    - sudo cpanm Dancer2::Plugin::DBIC
    - sqlite3 bookstore.db < bookstore.sql
    - sqlite3 bookstore.db < cpan.sql (Only if required)
    - SCHEMA_LOADER_BACKCOMPAT=1 perl populate_database.pl

RUN:

    - sudo plackup bin/app.psgi

FEATURE:

    - List authors and their books.
    - Add/Edit/Delete Author.
    - Add/Edit/Delete Book.
    - Search Author/Book.

Example 2: Continuation from Example 1

FEATURE:

    - Added AJAX call to Delete Book page.

Example 3: Continuation from Example 2

FEATURE:

    - Added login page and basic authentication.
    - Added register page.
    - Added logout functionality.

Example 4: Continuation from Example 3

FEATURE:

    - Experimented with Dancer2::Core::Error.
    - Added Chart using Highchart library with ajax call.

Example 5: Continuation from Example 4

FEATURE:

    - Implemented CAPTCHA to the login page.
    - Implemented CAPTCHA to the register page.

Example 6: Continuation from Example 5

FEATURE:

    - Implemented route chaining.
    - Added link 'Work', showing charts for GitHub/MetaCPAN favourites using route chaining.
    - Implemented Dancer2::Plugin::Res.