Componette

Componette

ldrahnik

ldrahnik / view-keeper v3.0

Keeper of app views.

download-cloud-line composer require ldrahnik/view-keeper

ldrahnik/view-keeper

Build Status Latest stable Downloads total

Keeper of app views.

Benefits

  • View-keeper is easy way to separate files from logic (e.g. separate to repositories, it has benefits, rights etc.)
  • Change location of files is now easier than ever before

Reference

Requirements

ldrahnik/view-keeper requires PHP 5.4 or higher.

Installation

Install keeper to your project using Composer:

$ composer require ldrahnik/view-keeper

Usage

Register extension in config file

extensions:
	keeper: ViewKeeper\DI\ViewKeeperExtension

keeper:
	controls: foo/controls/<name>/<view>
	files: foo/<name>/<view>

Is able to set up path via these patterns

	<module>		# <Backend>Module
	<name>			# <Backend>Module<:Base>Presenter
					# <Base>Presenter
					# <UserAdd>
	<view> 			# <default>.latte

Suffix is not configurable (still you can change that as param of getView method) - always will be in the end over dot

And inject

	/** @var \ViewKeeper\ViewKeeper @inject */
	private $keeper;

Summary

View keeper tries to be ultra-light package and simple to use. You will love it :)

For more information about path enrolment please check url-matcher

  • v3.0 v3.0 - Nette ~2.3

  • v2.1

  • v2.0

    • (BC break) removed magic methods support
    • being ultra-light package
  • v1.2.0

  • v1.1.0

    • Added Nette modules support
  • v1.0.0

    • Support for presenters, its means actions & layouts
    • Support for controls
  • v0.1

    First test version.

price-tag-2-line

Badges

guide-fill

Dependencies

php (>= 5.4)
nette/nette (~2.3.0)
Componette Componette felix@nette.org