@reinink reinink released this Dec 28, 2016

  • Added the ability to append content to sections using the new push() function.
  • Added an end() function as an alias to stop().



@reinink reinink released this Dec 27, 2016 · 5 commits to master since this release

  • Fixed an issue where template functions were not accessible from extensions.
  • Fixed an issued with the URI extension throwing errors when it shouldn't.
  • Added the ability to get all template data by calling $template->data().
  • Added the ability to render a template via the toString() magic method.
  • Added the ability to run the tests using composer test.
  • Improvements to error handling when rendering templates.
  • Various coding style, CI and documentation improvements.



@reinink reinink released this Jul 9, 2015 · 58 commits to master since this release

  • Fix bug related to output buffering and exceptions (#78).
  • Improvements to escaping (#56).
  • Various CI and packaging improvements.



@reinink reinink released this Oct 21, 2014 · 70 commits to master since this release

  • Added batch functionality to the escaping functions.



@reinink reinink released this Oct 20, 2014 · 75 commits to master since this release

  • Added ability to define the default content of a section.
  • Various code improvements (cleanup DocBlocks, class simplification, add Composer keywords, etc).



@reinink reinink released this Sep 30, 2014 · 84 commits to master since this release

  • Added all missing tests.
  • Improved custom function name validation.
  • Fixed bug with fallback folders, where the file extension wasn't being applied.
  • Improved error handling in Template class.



@reinink reinink released this Sep 28, 2014 · 99 commits to master since this release

  • Updated extension interface to ensure that an instance of the Engine class be passed to the register() method.
  • Minor code cleanup.



@reinink reinink released this Sep 27, 2014 · 103 commits to master since this release

  • Added ability to share data across templates.
  • Added ability to preassign data to specific templates.
  • Added ability to create one-off template functions, without using an extension.
  • Added new folder "fall backs", where missing folder templates will fall back to the default folder.
  • Added new render() method to Engine class, improving the use of the Engine as the primary API.
  • Templates variables are now accessed without the $this pseudo-variable.
  • Total overhaul to how extensions are registered. Replaced getFunctions() method with new register() method.
  • Section content is no longer assigned to template variables. Use the the section() function instead.
  • Renamed section end() function to stop(). This fits more appropriately with the start() function.
  • Renamed get() function to fetch().
  • Renamed pathExists() method in the Engine class to exists().
  • Renamed getTemplatePath() method in the Engine class to path().
  • Renamed makeTemplate() method in the Engine class to make().
  • Removed the ability to assign template data directly to the Template class. For example: $this->name = 'Jonathan'. This applies both within and outside of templates. Use the data() method instead.
  • Removed getEngine() method from the Template class. There's no reason to need this anymore.
  • Removed addFolders() method from the Engine() class.
  • Removed unloadExtension() and unloadExtensionFunction() methods from the Engine() class.



@reinink reinink released this Apr 2, 2014 · 128 commits to master since this release

  • Improved DocBlocks throughout the library.
  • The insert() functionality has been moved to a new extension, called Nest.
  • A new get() function was also added with this extension, which offers an alternative syntax for nesting templates.
  • Improved error messages.
  • A new error check which prevents the calling of the render() function from within templates themselves. If this functionally is required, use the nesting functions instead.
  • Added a clearer error message to the content() function when calling it from a non layout template.
  • Added a clearer error message to the batch() extension function when a provided function does not exist.
  • Fixed a bug in the engine where it was possible to overwrite a default extension when loading extensions.



@reinink reinink released this Mar 31, 2014 · 131 commits to master since this release

  • Added stacked layouts, allowing even further simplification and organization of templates.
  • Added new unloadExtension() and unloadExtensionFunction() methods to the Engine() class.
  • Added getEngine() method to the Template class.
  • Added addFolders() and loadExtensions() methods to the Engine() class.
  • Nested templates are now self-contained objects, with their own variables and layouts.