WP Manifestindependent plugin directory
manifest / utilities / pitea-customisation

Piteå Customisation

Custom functionality and modifications for the Pitea WordPress installation

★ 0stars
142composer installs

Install

Download source zip No release zip yet

This is the repository archive. It installs, but the folder name will carry the branch suffix and updates will not flow.

Install straight from GitHub with WP-CLI:

wp plugin install https://github.com/considbrs-webdev/pitea-customisation/archive/refs/heads/main.zip

On Packagist as considbrs-webdev/pitea-customisation:

composer require considbrs-webdev/pitea-customisation
No built-in updater. New versions won't appear under Dashboard → Updates. Install new releases yourself, or let Git Updater track the repository.

A WordPress plugin for custom functionality and modifications for the Pitea WordPress installation.

Features

  • Modular PHP architecture with Composer autoloading
  • Vite for modern CSS and JavaScript building
  • SCSS support with variables and mixins
  • Separate frontend and admin asset bundles

Requirements

  • PHP 8.0+
  • Node.js 18+
  • Composer

Installation

  1. Navigate to the plugin directory:

    cd wp-content/plugins/pitea-customisation
  2. Install PHP dependencies:

    composer install
  3. Install Node.js dependencies:

    npm install
  4. Build assets:

    npm run build
  5. Activate the plugin in WordPress admin.

Development

Watch for changes

npm run dev

Or for production watch:

npm run watch

Build for production

npm run build

Adding Custom Classes

  1. Create a new PHP class in source/php/Customisations/:

    <?php
    
    namespace PiteaCustomisation\Customisations;
    
    class MyCustomClass
    {
        public function __construct()
        {
            // Your hooks and initialization here
        }
    }
  2. Register the class in source/php/App.php:

    private function registerInstances(): void
    {
        $classes = [
            Customisations\IconReplacer::class,
            Customisations\MyCustomClass::class, // Add your class here
        ];
        // ...
    }
  3. Run composer dump-autoload to update the autoloader.

Directory Structure

pitea-customisation/
├── dist/                    # Built assets (generated)
├── source/
│   ├── js/
│   │   ├── main.js          # Frontend JavaScript entry
│   │   └── admin.js         # Admin JavaScript entry
│   ├── php/
│   │   ├── App.php          # Main plugin class
│   │   └── Customisations/  # Custom functionality classes
│   │       └── IconReplacer.php
│   └── sass/
│       ├── style.scss       # Frontend styles entry
│       ├── admin.scss       # Admin styles entry
│       └── abstracts/       # Variables, mixins, etc.
├── composer.json
├── package.json
├── vite.config.js
└── pitea-customisation.php  # Main plugin file

License

MIT