phpvms/resources/stubs/widgets/widget.stub

32 lines
471 B
Plaintext
Raw Normal View History

<?php
namespace {{namespace}};
use App\Interfaces\Widget;
/**
* Class {{class}}
* @package {{namespace}}
*/
class {{class}} extends Widget
{
/**
* The configuration array.
*/
protected $config = [
];
/**
* Treat this method as a controller action.
* Return view() or other content to display.
*/
public function run()
{
return view('{{view}}', [
'config' => $this->config,
]);
}
}