Dancer2::Plugin::LiteBlog - A minimalist, file-based blog engine for Dancer2.
This Dancer2 plugin provides a lightweight blogging engine. Instead of relying on a database, it utilizes flat files, primarily markdown and YAML, to store and manage content. Through this plugin, Dancer2 applications can seamlessly integrate a blog without the overhead of database management.
First, you need to scaffold Liteblog's assets in your Dancer2 application directory:
$ liteblog-scaffold .
Then, in your Dancer2 PSGI startup script:
# in your app.psgi
At build time, sets up essential configurations for the plugin and initializes the default routes.
Template::Toolkit is forced (all scaffolded views are designed to be TT views). Similarly, views tags are forced to TT's defaults: '[%' and '%]'.
A before_template hook is registered to populate tokens such as settings read from the liteblog config (liteblog entry in Dancer2's config) or the widgets elements (see Dancer2::Plugin::LiteBlog::Widget).
A default GET / route is defined and handles the landing page of the liteblog site.
A Liteblog app must call this keyword right after having use'ed Dancer2::Plugin::Liteblog. This allows to declare widget-specific routes (defined in the Widget's classes) once the config is fully read by Dancer2 (which is not the case at BUILD time).
This method also initializes all default tokens that will be passed to template calls.
Immediatly exits from the current route handler and render a 404 page with Liteblog's default templates.
Alexis Sukrieh, <sukria at gmail.com>
<sukria at gmail.com>
Please report any bugs or feature requests to bug-dancer2-plugin-liteblog at rt.cpan.org, or through the web interface at https://rt.cpan.org/NoAuth/ReportBug.html?Queue=Dancer2-Plugin-LiteBlog. I will be notified, and then you'll automatically be notified of progress on your bug as I make changes.
bug-dancer2-plugin-liteblog at rt.cpan.org
You can find documentation for this module with the perldoc command.
You can also look for information at:
RT: CPAN's request tracker (report bugs here)
GitHub Official Repository
The Author's personal site, built with Liteblog
This software is Copyright (c) 2023 by Alexis Sukrieh.
This is free software, licensed under:
The Artistic License 2.0 (GPL Compatible)
To install Dancer2::Plugin::LiteBlog, copy and paste the appropriate command in to your terminal.
perl -MCPAN -e shell
For more information on module installation, please visit the detailed CPAN module installation guide.