Work in progress!
Add this library as a Composer dependency to your plugin.
composer require wpsh/wp-plugin
<?php
use WPSH\Plugin;
if ( file_exists( __DIR__ . '/vendor/autoload.php' ) ) {
require( __DIR__ . '/vendor/autoload.php' );
}
$plugin = new Plugin\Plugin( __FILE__ );
// Now use it as a dependency for your own plugin.
$awesomePlugin = new AwesomePlugin( $plugin );
$awesomePlugin->init_hooks();
TODO: Build documentation from the docblock comments.
Created by Kaspars Dambis.