-
-
Notifications
You must be signed in to change notification settings - Fork 9.4k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feature #30959 [FrameworkBundle] [TwigBundle] Move the hinclude key a…
…way from templating (Simperfit) This PR was squashed before being merged into the 4.3-dev branch (closes #30959). Discussion ---------- [FrameworkBundle] [TwigBundle] Move the hinclude key away from templating | Q | A | ------------- | --- | Branch? | master | Bug fix? | no | New feature? | no <!-- don't forget to update src/**/CHANGELOG.md files --> | BC breaks? | no <!-- see https://symfony.com/bc --> | Deprecations? | yes <!-- don't forget to update UPGRADE-*.md and src/**/CHANGELOG.md files --> | Tests pass? | yes <!-- please add some, will be required by reviewers --> | Fixed tickets | #30874 <!-- #-prefixed issue number(s), if any --> | License | MIT | Doc PR | to do when pr is validated. <!-- Write a short README entry for your feature/bugfix here (replace this comment block.) This will help people understand your PR and can be used as a start of the Doc PR. Additionally: - Bug fixes must be submitted against the lowest branch where they apply (lowest branches are regularly merged to upper ones so they get the fixes too). - Features and deprecations must be submitted against the master branch. --> Maybe I shouldn't move directly the config key from templating to the other, but since the templating component has been deprecated we may change this directly without deprecating that key alone, WDYT ? Commits ------- 4f39339 [FrameworkBundle] [TwigBundle] Move the hinclude key away from templating
- Loading branch information
Showing
8 changed files
with
71 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
18 changes: 18 additions & 0 deletions
18
.../Bundle/FrameworkBundle/Tests/DependencyInjection/Fixtures/php/template_and_fragments.php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
<?php | ||
|
||
$container->loadFromExtension('framework', [ | ||
'templating' => [ | ||
'cache' => '/path/to/cache', | ||
'engines' => ['php', 'twig'], | ||
'loader' => ['loader.foo', 'loader.bar'], | ||
'form' => [ | ||
'resources' => ['theme1', 'theme2'], | ||
], | ||
'hinclude_default_template' => 'global_hinclude_template', | ||
], | ||
'assets' => null, | ||
'fragments' => [ | ||
'enabled' => true, | ||
'hinclude_default_template' => 'global_hinclude_template', | ||
], | ||
]); |
24 changes: 24 additions & 0 deletions
24
.../Bundle/FrameworkBundle/Tests/DependencyInjection/Fixtures/xml/template_and_fragments.xml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
<?xml version="1.0" ?> | ||
<container xmlns="http://symfony.com/schema/dic/services" | ||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" | ||
xmlns:framework="http://symfony.com/schema/dic/symfony" | ||
xsi:schemaLocation="http://symfony.com/schema/dic/services https://symfony.com/schema/dic/services/services-1.0.xsd | ||
http://symfony.com/schema/dic/symfony https://symfony.com/schema/dic/symfony/symfony-1.0.xsd"> | ||
|
||
<framework:config> | ||
<framework:fragments enabled="true" hinclude-default-template="global_hinclude_template"/> | ||
<framework:esi enabled="true" /> | ||
<framework:ssi enabled="true" /> | ||
<framework:assets /> | ||
<framework:templating cache="/path/to/cache" hinclude-default-template="global_hinclude_template"> | ||
<framework:loader>loader.foo</framework:loader> | ||
<framework:loader>loader.bar</framework:loader> | ||
<framework:engine>php</framework:engine> | ||
<framework:engine>twig</framework:engine> | ||
<framework:form> | ||
<framework:resource>theme1</framework:resource> | ||
<framework:resource>theme2</framework:resource> | ||
</framework:form> | ||
</framework:templating> | ||
</framework:config> | ||
</container> |
12 changes: 12 additions & 0 deletions
12
.../Bundle/FrameworkBundle/Tests/DependencyInjection/Fixtures/yml/template_and_fragments.yml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
framework: | ||
fragments: | ||
enabled: true | ||
hinclude_default_template: global_hinclude_template | ||
templating: | ||
engines: [php, twig] | ||
loader: [loader.foo, loader.bar] | ||
cache: /path/to/cache | ||
form: | ||
resources: [theme1, theme2] | ||
hinclude_default_template: global_hinclude_template | ||
assets: ~ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters