PHP code example of tapestry-cloud / code-example-plugin
1. Go to this page and download the library: Download tapestry-cloud/code-example-plugin library. Choose the download type require. 2. Extract the ZIP file and open the index.php. 3. Add this code to the index.php.
<?php
require_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
tapestry-cloud / code-example-plugin example snippets
// ...
'plugins' => [
'code_example_path' => __DIR__ . '/code_examples/'
],
// ...
use Tapestry\Modules\Kernel\KernelInterface;
class Kernel implements KernelInterface
{
/**
* @var Tapestry
*/
private $tapestry;
public function __construct(Tapestry $tapestry)
{
$this->tapestry = $tapestry;
}
/**
* This method is executed by Tapestry when the Kernel is registered.
*
* @return void
*/
public function register()
{
// Use project autoloader