Commit Graph

685 Commits

Author SHA1 Message Date
Fabien Potencier bba5e1a1b3 removed obsolete comment 2016-09-22 08:15:13 -07:00
Fabien Potencier 349b0885cd fixed docs 2016-09-21 13:27:56 -07:00
Nathan Perry 9c6b8cb3e4 Expanded definition of empty 2016-09-21 13:27:28 -07:00
Fabien Potencier 21039777d8 minor #2062 [DOC] add named macro end-tag documentation (JakeFr)
This PR was merged into the 1.x branch.

Discussion
----------

[DOC] add named macro end-tag documentation

Hello!
Just discover endmacro tag supports name, just like block.
But it is not mentionned in the doc.
So here's a PR

Commits
-------

dcc5f45 add named macro end-tag documentation
2016-08-15 10:25:09 -07:00
Grégoire Paris 507f697ad0 Do not mix indention levels
Not sure if this was intentional, but the "if" line had an indention of 3 spaces,
while the "true" line has an indention of 4 spaces.
2016-08-15 10:21:29 -07:00
Fabien Potencier b7cd3a88dc fixed typo 2016-07-28 16:58:48 -04:00
Svante Richter e8b16c0693 Add Visual Studio Code to the list of IDE integrations
With the "TWIG pack" extension.
2016-07-28 16:58:12 -04:00
Thomas Schulz dc798d3bbb [Doc] Fixed small error in code example 2016-07-10 09:48:21 +02:00
Aaron Wallentine 080054501f Update macro.rst
Small grammar fix: subject-verb agreement "Macros differ" vs "Macros differs"
2016-06-24 07:05:43 +02:00
Aaron Wallentine 08c830a5aa Update use.rst
Small grammar fix.
2016-06-24 07:05:20 +02:00
JakeFr dcc5f450de add named macro end-tag documentation 2016-06-21 11:36:37 +02:00
Javier Eguiluz b42ddb3989 Minor rst syntax tweaks 2016-06-13 10:25:29 +02:00
Sam e81e698187 Small fixes 2016-05-20 08:13:46 +02:00
Owen Kieffer-Jones 6dd784a2d5 Grammar 2016-05-13 14:46:43 -05:00
JakeFr 1a1ba8bba4 [DOC] recipes.rst uses Twig_Function_Function
Hello,
Here's a minor update for recipes.rst
I rewrite the code sample for registerUndefinedFunctionCallback to remove usage of deprecated class Twig_Function_Function.
2016-05-13 18:05:38 +02:00
Christian Flothmann e317c559a8 fix a typo (add missing article) 2016-04-21 09:43:05 +02:00
Darren Black b8a987ee33 Implement Twig_Extension_GlobalsInterface on getGlobals example 2016-04-20 08:47:42 +02:00
Fabien Potencier 3223e58253 minor #2005 [Doc] Add a note about escaping backslashes inside strings (javiereguiluz)
This PR was squashed before being merged into the 1.x branch (closes #2005).

Discussion
----------

[Doc] Add a note about escaping backslashes inside strings

Backslashes inside strings caused some confusion for some users. See https://github.com/symfony/symfony/issues/18207

Commits
-------

463ea80 [Doc] Add a note about escaping backslashes inside strings
2016-04-20 08:46:54 +02:00
Javier Eguiluz 463ea80126 [Doc] Add a note about escaping backslashes inside strings 2016-04-20 08:46:52 +02:00
Fabien Potencier 5cfdb76931 minor #2016 Promote the include() function instead of the "include" tag (javiereguiluz)
This PR was merged into the 1.x branch.

Discussion
----------

Promote the include() function instead of the "include" tag

The `{% include %}` tag is pseudo-officially deprecated in favor of the `include()` function. Let's update the documentation to promote the function instead of the tag.

Commits
-------

ea090df Promote the include() function instead of the "include" tag
2016-04-20 08:46:02 +02:00
Javier Eguiluz 4788e53d04 Fixed minor syntax issues in templates.rst 2016-04-17 19:46:21 +02:00
Javier Eguiluz ea090df8d9 Promote the include() function instead of the "include" tag 2016-04-17 19:40:15 +02:00
iamluc ed8aa84881 Fix documentation, recipes section 2016-01-29 11:18:56 +01:00
Fabien Potencier cdd57f33b5 adding support for the ?? operator 2016-01-25 17:15:20 +01:00
Fabien Potencier b490e6594f undeprecated _self 2016-01-16 06:36:39 +01:00
Matthias Althaus 57cd302f50 [DOC] Fixed typos in advanced.rst
There are two typos of `Interace`. Although it sounds cool, `Interface` works better for copy and paste.
2016-01-07 22:43:13 +01:00
Possum 0f5f9aaf2a Typo in doc 2015-11-05 10:22:46 +01:00
Christian Raue 2660286d28 fixed Twig_Extension_GlobalsInterface name in comments 2015-11-02 13:15:25 +01:00
Fabien Potencier e3a325f249 deprecated Twig_ExtensionInterface::getGlobals() 2015-10-29 16:13:49 -07:00
Fabien Potencier 9774f4f1a4 deprecated Twig_ExtensionInterface::initRuntime() 2015-10-25 15:48:46 +01:00
Fabien Potencier eac8c0cd3f removed obsolete documentation about requiring classes 2015-10-21 08:17:22 +02:00
Fabien Potencier 38029206d2 added a note about using .. and | together 2015-10-12 09:39:52 +02:00
Fabien Potencier 2b6cfc01aa fixed recipe 2015-09-13 18:56:37 +02:00
Fabien Potencier b673f65d34 feature #1823 rewrote the recipes about APC and opcache to avoid deprecation notices (fabpot)
This PR was merged into the 1.x branch.

Discussion
----------

rewrote the recipes about APC and opcache to avoid deprecation notices

Commits
-------

96a54b3 added an option to force PHP bytecode invalidation when writing a compiled template into the cache
e9b0802 rewrote the recipes about APC and opcache to avoid deprecation notices
2015-09-13 13:17:46 +02:00
Fabien Potencier 77fed4e659 added a recipe about how to render a template stored as a string 2015-09-13 12:37:19 +02:00
Fabien Potencier 96a54b3f40 added an option to force PHP bytecode invalidation when writing a compiled template into the cache 2015-09-13 12:26:27 +02:00
Fabien Potencier e9b08026b3 rewrote the recipes about APC and opcache to avoid deprecation notices 2015-09-13 12:12:56 +02:00
Fabien Potencier b5c7f5cd5a added a note about Twig_Loader_String alternatives 2015-09-13 08:53:43 +02:00
Fabien Potencier 0157315e59 deprecated Twig_Environment::getTemplateClassPrefix 2015-09-12 15:34:51 +02:00
Fabien Potencier 4d6d3a5944 fixed deprecation docs 2015-09-11 16:58:04 +02:00
Fabien Potencier cacfb069b2 added a cache interface for templates 2015-09-11 16:24:57 +02:00
Fabien Potencier 542dd3acc0 feature #1795 Traversable support for 'replace', 'merge' and 'sort' (SpacePossum)
This PR was merged into the 1.x branch.

Discussion
----------

Traversable support for 'replace', 'merge' and 'sort'

Add traversable support to:
* replace
* merge
* sort

Other changes:
* Removes some not need checks
* ~~Make unit test skip if it cannot write to cache because of the user running the test~~
* Tests added for traversable support
* Doc updates

Deprecating:
I think the undocumented (and multibyte not supported) use of `replace(string, string)` can be removed in Twig 2.0.
Adding MB support and documentation of the feature was turned down (https://github.com/twigphp/Twig/pull/1618)
However removing it is a BC break (https://github.com/twigphp/Twig/pull/1445#issuecomment-48746926)

Commits
-------

2a17303 Mark test skipped if cannot write to cache directory.
2015-09-06 08:43:16 +02:00
Possum 2a17303601 Mark test skipped if cannot write to cache directory.
Add Traversable support for replace, sort and merge filters.
2015-08-28 11:14:03 +02:00
Alexander Vasilyev 2c4af24b20 OPcache support fix 2015-08-27 09:47:21 +02:00
Fabien Potencier bc9911e326 added a note about TwigFiddle 2015-08-23 14:22:16 +02:00
Fabien Potencier 56c7382775 added Twig_Util_DeprecationCollector to collect deprecation notices for a set of templates 2015-08-18 13:34:47 +02:00
Fabien Potencier bd87ba8ad0 added some documentation about deprecation notices 2015-08-18 13:34:46 +02:00
Fabien Potencier c27b04c9d6 added the raw tag as being deprecated 2015-08-15 23:53:21 +02:00
Fabien Potencier af129b2f75 fixed typos and CS 2015-08-13 14:50:40 +02:00
Alexander Vasilyev 1f3fb9a178 [doc/recipes] Added OPcache support 2015-08-13 14:49:08 +02:00