Skip to content

Commit 168072b

Browse files
committed
[#5973] some minor tweaks
1 parent 433dd04 commit 168072b

File tree

10 files changed

+19
-48
lines changed

10 files changed

+19
-48
lines changed

Diff for: best_practices/web-assets.rst

+1-5
Original file line numberDiff line numberDiff line change
@@ -35,11 +35,7 @@ much more concise:
3535
Using Assetic
3636
-------------
3737

38-
.. caution::
39-
40-
Starting from Symfony 2.8, Assetic is no longer included by default in the
41-
Symfony Standard Edition. Refer to :doc:`this article </cookbook/assetic/asset_management>`
42-
to learn how to install and enable Assetic in your Symfony application.
38+
.. include:: /cookbook/assetic/_standard_edition_warning.inc
4339

4440
These days, you probably can't simply create static CSS and JavaScript files
4541
and include them in your template. Instead, you'll probably want to combine

Diff for: cookbook/assetic/_standard_edition_warning.inc

+5
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
.. caution::
2+
3+
Starting from Symfony 2.8, Assetic is no longer included by default in the
4+
Symfony Standard Edition. Refer to :doc:`this article </cookbook/assetic/asset_management>`
5+
to learn how to install and enable Assetic in your Symfony application.

Diff for: cookbook/assetic/apply_to_option.rst

+1-5
Original file line numberDiff line numberDiff line change
@@ -4,11 +4,7 @@
44
How to Apply an Assetic Filter to a specific File Extension
55
===========================================================
66

7-
.. caution::
8-
9-
Starting from Symfony 2.8, Assetic is no longer included by default in the
10-
Symfony Standard Edition. Refer to :doc:`this article </cookbook/assetic/asset_management>`
11-
to learn how to install and enable Assetic in your Symfony application.
7+
.. include:: /cookbook/assetic/_standard_edition_warning.inc
128

139
Assetic filters can be applied to individual files, groups of files or even,
1410
as you'll see here, files that have a specific extension. To show you how

Diff for: cookbook/assetic/asset_management.rst

+6-8
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ AsseticBundle executing this console command in your project:
1515
1616
$ composer require symfony/assetic-bundle
1717
18-
Then, enable the bundle in the ``AppKernel`` file of your Symfony application::
18+
Then, enable the bundle in the ``AppKernel.php`` file of your Symfony application::
1919

2020
// app/AppKernel.php
2121

@@ -44,8 +44,8 @@ your application:
4444
4545
# app/config/config.yml
4646
assetic:
47-
debug: "%kernel.debug%"
48-
use_controller: false
47+
debug: '%kernel.debug%'
48+
use_controller: '%kernel.debug%'
4949
filters:
5050
cssrewrite: ~
5151
@@ -57,12 +57,11 @@ your application:
5757
<?xml version="1.0" encoding="UTF-8" ?>
5858
<container xmlns="http://symfony.com/schema/dic/services"
5959
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
60-
xmlns:framework="http://symfony.com/schema/dic/symfony"
61-
xmlns:twig="http://symfony.com/schema/dic/twig"
60+
xmlns:assetic="http://symfony.com/schema/dic/assetic"
6261
xsi:schemaLocation="http://symfony.com/schema/dic/services
6362
http://symfony.com/schema/dic/services/services-1.0.xsd
64-
http://symfony.com/schema/dic/symfony
65-
http://symfony.com/schema/dic/symfony/symfony-1.0.xsd">
63+
http://symfony.com/schema/dic/assetic
64+
http://symfony.com/schema/dic/assetic/assetic-1.0.xsd">
6665
6766
<assetic:config debug="%kernel.debug%" use-controller="%kernel.debug%">
6867
<assetic:filters cssrewrite="null" />
@@ -74,7 +73,6 @@ your application:
7473
.. code-block:: php
7574
7675
// app/config/config.php
77-
7876
$container->loadFromExtension('assetic', array(
7977
'debug' => '%kernel.debug%',
8078
'use_controller' => '%kernel.debug%',

Diff for: cookbook/assetic/index.rst

+1-5
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,7 @@
11
Assetic
22
=======
33

4-
.. caution::
5-
6-
Starting from Symfony 2.8, Assetic is no longer included by default in the
7-
Symfony Standard Edition. Refer to :doc:`this article </cookbook/assetic/asset_management>`
8-
to learn how to install and enable Assetic in your Symfony application.
4+
.. include:: /cookbook/assetic/_standard_edition_warning.inc
95

106
.. toctree::
117
:maxdepth: 2

Diff for: cookbook/assetic/jpeg_optimize.rst

+1-5
Original file line numberDiff line numberDiff line change
@@ -4,11 +4,7 @@
44
How to Use Assetic for Image Optimization with Twig Functions
55
=============================================================
66

7-
.. caution::
8-
9-
Starting from Symfony 2.8, Assetic is no longer included by default in the
10-
Symfony Standard Edition. Refer to :doc:`this article </cookbook/assetic/asset_management>`
11-
to learn how to install and enable Assetic in your Symfony application.
7+
.. include:: /cookbook/assetic/_standard_edition_warning.inc
128

139
Among its many filters, Assetic has four filters which can be used for on-the-fly
1410
image optimization. This allows you to get the benefits of smaller file sizes

Diff for: cookbook/assetic/php.rst

+1-5
Original file line numberDiff line numberDiff line change
@@ -4,11 +4,7 @@
44
Combining, Compiling and Minimizing Web Assets with PHP Libraries
55
=================================================================
66

7-
.. caution::
8-
9-
Starting from Symfony 2.8, Assetic is no longer included by default in the
10-
Symfony Standard Edition. Refer to :doc:`this article </cookbook/assetic/asset_management>`
11-
to learn how to install and enable Assetic in your Symfony application.
7+
.. include:: /cookbook/assetic/_standard_edition_warning.inc
128

139
The official Symfony Best Practices recommend to use Assetic to
1410
:doc:`manage web assets </best_practices/web-assets>`, unless you are

Diff for: cookbook/assetic/uglifyjs.rst

+1-5
Original file line numberDiff line numberDiff line change
@@ -4,11 +4,7 @@
44
How to Minify CSS/JS Files (Using UglifyJS and UglifyCSS)
55
=========================================================
66

7-
.. caution::
8-
9-
Starting from Symfony 2.8, Assetic is no longer included by default in the
10-
Symfony Standard Edition. Refer to :doc:`this article </cookbook/assetic/asset_management>`
11-
to learn how to install and enable Assetic in your Symfony application.
7+
.. include:: /cookbook/assetic/_standard_edition_warning.inc
128

139
`UglifyJS`_ is a JavaScript parser/compressor/beautifier toolkit. It can be used
1410
to combine and minify JavaScript assets so that they require less HTTP requests

Diff for: cookbook/assetic/yuicompressor.rst

+1-5
Original file line numberDiff line numberDiff line change
@@ -10,11 +10,7 @@ How to Minify JavaScripts and Stylesheets with YUI Compressor
1010
**strongly advised to avoid using YUI utilities** unless strictly necessary.
1111
Read :doc:`/cookbook/assetic/uglifyjs` for a modern and up-to-date alternative.
1212

13-
.. caution::
14-
15-
Starting from Symfony 2.8, Assetic is no longer included by default in the
16-
Symfony Standard Edition. Refer to :doc:`this article </cookbook/assetic/asset_management>`
17-
to learn how to install and enable Assetic in your Symfony application.
13+
.. include:: /cookbook/assetic/_standard_edition_warning.inc
1814

1915
Yahoo! provides an excellent utility for minifying JavaScripts and stylesheets
2016
so they travel over the wire faster, the `YUI Compressor`_. Thanks to Assetic,

Diff for: reference/configuration/assetic.rst

+1-5
Original file line numberDiff line numberDiff line change
@@ -4,11 +4,7 @@
44
AsseticBundle Configuration ("assetic")
55
=======================================
66

7-
.. caution::
8-
9-
Starting from Symfony 2.8, Assetic is no longer included by default in the
10-
Symfony Standard Edition. Refer to :doc:`this article </cookbook/assetic/asset_management>`
11-
to learn how to install and enable Assetic in your Symfony application.
7+
.. include:: /cookbook/assetic/_standard_edition_warning.inc
128

139
Full Default Configuration
1410
--------------------------

0 commit comments

Comments
 (0)