pedrosancao / wordimpress
Static site generator library using Wordpress API as content source.
Requires
- php: >=7.1.0
- ext-dom: *
- ext-gd: *
- ext-inotify: *
- erusev/parsedown: ^1.7
- twig/intl-extra: ^3.0
- twig/markdown-extra: ^3.0
- twig/twig: ^3.0
Requires (Dev)
This package is auto-updated.
Last update: 2024-11-07 22:36:02 UTC
README
Static site generator library that uses Wordpress API as content source. The library still a prototype.
Key features
- uses Twig as template engine
- convert images to WebP format
- supports markdown to HTML
Dependencies
This package rely on these PHP extensions:
- GD
- DOM
- Inotify
Make sure you have them installed.
Usage
Add Wordimpress to your project using composer:
composer require pedrosancao/wordimpress
Create a class implementing PedroSancao\Wordimpress\Contracts\SiteInterface
, then implement other
interfaces on the namespace PedroSancao\Wordimpress\Contracts
to add more capabilities, some of them
have traits that implements the interface (PedroSancao\Wordimpress\BlogData\Has*Trait
).
Invoke wordpress command:
vendor/bin/wordimpress [options] classname
classname
is the full qualified name of the class implementing SiteInterface
The available options:
-p, --production
generate assets production-w, --watch
watch for changes to recompile--html-only
run only HTML generation (prevents-w
)
An example of usage is available on Bootstrap Template.
To do
Check the project's kanban board.