Skip to content

sdtorresl/materialize-theme

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

11 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

MaterializeTheme plugin for CakePHP

This plugin provides easy to use materialize theme in CakePHP 4.x

preview

Prerequisites

A complete CakePHP environment is required for this proyect.

In this repository you can deploy a clean environment with all dependencies ready for develop CakePHP applications.

Installation

You can install this plugin into your CakePHP application using composer.

The recommended way to install composer packages is:

composer require sdtorresl/materialize-theme:dev-master

Configuration

Load the plugin in your src/Application.php file (bootsrap() method):

$this->addPlugin('MaterializeTheme');

To set the default bake template add the follow lines to config/bootstrap.php:

Configure::write('Bake.theme', 'MaterializeTheme');

To set the default layout in AppController add the follow method:

use Cake\Event\EventInterface;
[...]
public function beforeRender(EventInterface $event) {
    parent::beforeRender($event);

    $this->viewBuilder()->setLayout('MaterializeTheme.materialize');
}

Extending plugin templates

If you need to extend the templates follow the next steps:

cd APP_HOME
mkdir -p templates/plugin/sdtorresl/materialize-theme
cp -r vendor/sdtorresl/materialize-theme/templates/ templates/plugin/sdtorresl/materialize-theme/

More info related with overriding is available here:

Authors

Sergio Torres

License

This project is licensed under the MIT License - see the LICENSE.md file for details

Support

Have issues? Write to our support mail

About

A materializecss theme for CakePHP 4.x

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published