animafac / minisites
Custom post type used to integrate former mini-websites on animafac.net
Requires (Dev)
- 10up/wp_mock: ~0.1.0
- mockery/mockery: ~0.9.5
- phpunit/phpunit: ~5.5.2
- squizlabs/php_codesniffer: ~2.6.2
This package is not auto-updated.
Last update: 2024-10-19 19:17:58 UTC
README
Custom post type used to integrate former mini-websites on animafac.net
How it works
Minisite::init()
adds a new minisite_page
custom post type that can be grouped with the minisite
taxonomy.
Our WordPress theme then displays this custom post type has a series of pages with a common TOC.
You can see an example here.
Grunt tasks
Grunt can be used to run some automated tasks defined in Gruntfile.js
.
Your first need to install dependencies with Yarn and Composer:
yarn install
composer install
Be careful to not commit these dependencies in the repository!
You can remove them like this:
composer install --no-dev
(We can't add vendor/
to .gitignore
because we need to include autoload into the repository in case the plugin is installed with the regular WordPress installer and not Composer.)
Lint
You can check that the JavaScript, JSON and PHP files are formatted correctly:
grunt lint
Tests
You can run PHPUnit tests:
grunt test
Translation template
You can update the POT translation template:
grunt makepot
CI
Gitlab CI is used to run the tests automatically after each commit.