Skip to content

Commit 6f30499

Browse files
committed
be keen to newcomers
1 parent 8f3e142 commit 6f30499

26 files changed

+44
-50
lines changed

bundles/extension.rst

+1-1
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ following conventions:
2929

3030
The Extension class should implement the
3131
:class:`Symfony\\Component\\DependencyInjection\\Extension\\ExtensionInterface`,
32-
but usually you would simply extend the
32+
but usually you would extend the
3333
:class:`Symfony\\Component\\DependencyInjection\\Extension\\Extension` class::
3434

3535
// src/Acme/HelloBundle/DependencyInjection/AcmeHelloExtension.php

bundles/override.rst

+2-2
Original file line numberDiff line numberDiff line change
@@ -29,8 +29,8 @@ the routes from any bundle, then they must be manually imported from somewhere
2929
in your application (e.g. ``app/config/routing.yml``).
3030

3131
The easiest way to "override" a bundle's routing is to never import it at
32-
all. Instead of importing a third-party bundle's routing, simply copy
33-
that routing file into your application, modify it, and import it instead.
32+
all. Instead of importing a third-party bundle's routing, copy that
33+
routing file into your application, modify it, and import it instead.
3434

3535
Controllers
3636
-----------

components/debug.rst

+2-2
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ Usage
2222
-----
2323

2424
The Debug component provides several tools to help you debug PHP code.
25-
Enabling them all is as easy as it can get::
25+
Enabling them all by calling this method::
2626

2727
use Symfony\Component\Debug\Debug;
2828

@@ -83,7 +83,7 @@ throw more helpful exceptions when a class isn't found by the registered
8383
autoloaders. All autoloaders that implement a ``findFile()`` method are replaced
8484
with a ``DebugClassLoader`` wrapper.
8585

86-
Using the ``DebugClassLoader`` is as easy as calling its static
86+
Using the ``DebugClassLoader`` is done by calling its static
8787
:method:`Symfony\\Component\\Debug\\DebugClassLoader::enable` method::
8888

8989
use Symfony\Component\Debug\DebugClassLoader;

components/http_foundation.rst

+3-3
Original file line numberDiff line numberDiff line change
@@ -245,7 +245,7 @@ the previous requests.
245245
Accessing ``Accept-*`` Headers Data
246246
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
247247

248-
You can easily access basic data extracted from ``Accept-*`` headers
248+
You can access basic data extracted from ``Accept-*`` headers
249249
by using the following methods:
250250

251251
:method:`Symfony\\Component\\HttpFoundation\\Request::getAcceptableContentTypes`
@@ -490,8 +490,8 @@ Serving Files
490490
~~~~~~~~~~~~~
491491

492492
When sending a file, you must add a ``Content-Disposition`` header to your
493-
response. While creating this header for basic file downloads is easy, using
494-
non-ASCII filenames is more involving. The
493+
response. While creating this header for basic file downloads is straightforward,
494+
using non-ASCII filenames is more involving. The
495495
:method:`Symfony\\Component\\HttpFoundation\\ResponseHeaderBag::makeDisposition`
496496
abstracts the hard work behind a simple API::
497497

components/http_kernel.rst

+1-1
Original file line numberDiff line numberDiff line change
@@ -174,7 +174,7 @@ to the login page or a 403 Access Denied response.
174174
If a ``Response`` is returned at this stage, the process skips directly to
175175
the :ref:`kernel.response <component-http-kernel-kernel-response>` event.
176176

177-
Other listeners simply initialize things or add more information to the request.
177+
Other listeners initialize things or add more information to the request.
178178
For example, a listener might determine and set the locale on the ``Request``
179179
object.
180180

components/stopwatch.rst

+1-1
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ Alternatively, you can clone the `<https://github.com/symfony/stopwatch>`_ repos
2121
Usage
2222
-----
2323

24-
The Stopwatch component provides an easy and consistent way to measure execution
24+
The Stopwatch component provides an consistent way to measure execution
2525
time of certain parts of code so that you don't constantly have to parse
2626
microtime by yourself. Instead, use the simple
2727
:class:`Symfony\\Component\\Stopwatch\\Stopwatch` class::

components/templating.rst

+2-3
Original file line numberDiff line numberDiff line change
@@ -144,9 +144,8 @@ escaper using the
144144
Helpers
145145
-------
146146

147-
The Templating component can be easily extended via helpers. Helpers are PHP objects that
148-
provide features useful in a template context. The component has
149-
one built-in helper:
147+
The Templating component can be extended via helpers. Helpers are PHP objects that
148+
provide features useful in a template context. The component has one built-in helper:
150149

151150
* :doc:`/components/templating/slotshelper`
152151

console/input.rst

+1-1
Original file line numberDiff line numberDiff line change
@@ -119,7 +119,7 @@ Using Command Options
119119
Unlike arguments, options are not ordered (meaning you can specify them in any
120120
order) and are specified with two dashes (e.g. ``--yell``). Options are
121121
*always* optional, and can be setup to accept a value (e.g. ``--dir=src``) or
122-
simply as a boolean flag without a value (e.g. ``--yell``).
122+
as a boolean flag without a value (e.g. ``--yell``).
123123

124124
For example, add a new option to the command that can be used to specify
125125
how many times in a row the message should be printed::

console/request_context.rst

+1-1
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,7 @@ will override the defaults.
7272
Configuring the Request Context per Command
7373
-------------------------------------------
7474

75-
To change it only in one command you can simply fetch the Request Context
75+
To change it only in one command you need to fetch the Request Context
7676
from the ``router`` service and override its settings::
7777

7878
// src/AppBundle/Command/DemoCommand.php

create_framework/dependency_injection.rst

+4-4
Original file line numberDiff line numberDiff line change
@@ -66,15 +66,15 @@ framework more configurable, but at the same time, it introduces a lot of
6666
issues:
6767

6868
* We are not able to register custom listeners anymore as the dispatcher is
69-
not available outside the Framework class (an easy workaround could be the
69+
not available outside the Framework class (an workaround could be the
7070
adding of a ``Framework::getEventDispatcher()`` method);
7171

7272
* We have lost the flexibility we had before; you cannot change the
7373
implementation of the ``UrlMatcher`` or of the ``ControllerResolver``
7474
anymore;
7575

76-
* Related to the previous point, we cannot test our framework easily anymore
77-
as it's impossible to mock internal objects;
76+
* Related to the previous point, we cannot test our framework without much
77+
effort anymore as it's impossible to mock internal objects;
7878

7979
* We cannot change the charset passed to ``ResponseListener`` anymore (a
8080
workaround could be to pass it as a constructor argument).
@@ -234,7 +234,7 @@ And the related change in the front controller::
234234

235235
$container->setParameter('routes', include __DIR__.'/../src/app.php');
236236

237-
We have obviously barely scratched the surface of what you can do with the
237+
We have barely scratched the surface of what you can do with the
238238
container: from class names as parameters, to overriding existing object
239239
definitions, from shared service support to dumping a container to a plain PHP class,
240240
and much more. The Symfony dependency injection container is really powerful

create_framework/event_dispatcher.rst

+1-2
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,7 @@ The EventDispatcher Component
33

44
Our framework is still missing a major characteristic of any good framework:
55
*extensibility*. Being extensible means that the developer should be able to
6-
easily hook into the framework life cycle to modify the way the request is
7-
handled.
6+
hook into the framework life cycle to modify the way the request is handled.
87

98
What kind of hooks are we talking about? Authentication or caching for
109
instance. To be flexible, hooks must be plug-and-play; the ones you "register"

create_framework/front_controller.rst

+2-2
Original file line numberDiff line numberDiff line change
@@ -61,8 +61,8 @@ which name is exposed to the end user via the URL
6161
(``http://127.0.0.1:4321/bye.php``): there is a direct mapping between the PHP
6262
script name and the client URL. This is because the dispatching of the request
6363
is done by the web server directly. It might be a good idea to move this
64-
dispatching to our code for better flexibility. This can be easily achieved by
65-
routing all client requests to a single PHP script.
64+
dispatching to our code for better flexibility. This can be achieved by routing
65+
all client requests to a single PHP script.
6666

6767
.. tip::
6868

create_framework/http_kernel_httpkernel_class.rst

+3-4
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ The HttpKernel Component: The HttpKernel Class
44
If you were to use our framework right now, you would probably have to add
55
support for custom error messages. We do have 404 and 500 error support but
66
the responses are hardcoded in the framework itself. Making them customizable
7-
is easy enough though: dispatch a new event and listen to it. Doing it right
7+
is straightforward though: dispatch a new event and listen to it. Doing it right
88
means that the listener has to call a regular controller. But what if the
99
error controller throws an exception? You will end up in an infinite loop.
1010
There should be an easier way, right?
@@ -114,9 +114,8 @@ client; that's what the ``ResponseListener`` does::
114114

115115
$dispatcher->addSubscriber(new HttpKernel\EventListener\ResponseListener('UTF-8'));
116116

117-
This one was easy too! Let's take another one: do you want out of the box
118-
support for streamed responses? Just subscribe to
119-
``StreamedResponseListener``::
117+
If you want out of the box support for streamed responses, subscribe
118+
to ``StreamedResponseListener``::
120119

121120
$dispatcher->addSubscriber(new HttpKernel\EventListener\StreamedResponseListener());
122121

create_framework/http_kernel_httpkernelinterface.rst

+1-1
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ Update your framework so that it implements this interface::
4646
}
4747
}
4848

49-
Even if this change looks trivial, it brings us a lot! Let's talk about one of
49+
Even if this change looks not to complex, it brings us a lot! Let's talk about one of
5050
the most impressive one: transparent :doc:`HTTP caching </http_cache>` support.
5151

5252
The ``HttpCache`` class implements a fully-featured reverse proxy, written in

create_framework/routing.rst

+1-1
Original file line numberDiff line numberDiff line change
@@ -189,7 +189,7 @@ more flexible than the previous one. Enjoy!
189189
Using the Routing component has one big additional benefit: the ability to
190190
generate URLs based on Route definitions. When using both URL matching and URL
191191
generation in your code, changing the URL patterns should have no other
192-
impact. Want to know how to use the generator? Insanely easy::
192+
impact. You can use the generator this way::
193193

194194
use Symfony\Component\Routing;
195195

create_framework/separation_of_concerns.rst

+1-1
Original file line numberDiff line numberDiff line change
@@ -171,7 +171,7 @@ a well defined goal:
171171
our application;
172172

173173
* ``src/Simplex``: The reusable framework code that abstracts the handling of
174-
incoming Requests (by the way, it makes your controllers/templates easily
174+
incoming Requests (by the way, it makes your controllers/templates better
175175
testable -- more about that later on);
176176

177177
* ``src/Calendar``: Our application specific code (the controllers and the

create_framework/unit_testing.rst

+1-1
Original file line numberDiff line numberDiff line change
@@ -136,7 +136,7 @@ Executing this test is as simple as running ``phpunit`` from the
136136
After the test ran, you should see a green bar. If not, you have a bug
137137
either in the test or in the framework code!
138138

139-
Adding a unit test for any exception thrown in a controller is just as easy::
139+
Adding a unit test for any exception thrown in a controller::
140140

141141
public function testErrorHandling()
142142
{

http_cache.rst

+3-4
Original file line numberDiff line numberDiff line change
@@ -77,9 +77,8 @@ but is a great way to start.
7777

7878
For details on setting up Varnish, see :doc:`/http_cache/varnish`.
7979

80-
Enabling the proxy is easy: each application comes with a caching kernel (``AppCache``)
81-
that wraps the default one (``AppKernel``). The caching Kernel *is* the reverse
82-
proxy.
80+
Each application comes with a caching kernel (``AppCache``)that wraps the
81+
default one (``AppKernel``). The caching Kernel *is* the reverse proxy.
8382

8483
To enable caching, modify the code of your front controller. You can also make these
8584
changes to ``app_dev.php`` to add caching to the ``dev`` environment::
@@ -267,7 +266,7 @@ Validation Caching
267266
single: Cache; Cache-Control header
268267
single: HTTP headers; Cache-Control
269268

270-
With expiration caching, you simply say "cache for 3600 seconds!". But, when someone
269+
With expiration caching, you say "cache for 3600 seconds!". But, when someone
271270
updates cached content, you won't see that content on your site until the cache
272271
expires.
273272

reference/constraints/Collection.rst

+1-1
Original file line numberDiff line numberDiff line change
@@ -163,7 +163,7 @@ following:
163163
Presence and Absence of Fields
164164
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
165165

166-
By default, this constraint validates more than simply whether or not the
166+
By default, this constraint validates more than whether or not the
167167
individual fields in the collection pass their assigned constraints. In
168168
fact, if any keys of a collection are missing or if there are any unrecognized
169169
keys in the collection, validation errors will be thrown.

reference/constraints/IsNull.rst

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ IsNull
22
======
33

44
Validates that a value is exactly equal to ``null``. To force that a property
5-
is simply blank (blank string or ``null``), see the :doc:`/reference/constraints/Blank`
5+
is blank (blank string or ``null``), see the :doc:`/reference/constraints/Blank`
66
constraint. To ensure that a property is not null, see :doc:`/reference/constraints/NotNull`.
77

88
Also see :doc:`NotNull <NotNull>`.

reference/constraints/NotBlank.rst

+1-1
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ a blank array, ``null`` or ``false``::
88
// validation will fail
99
}
1010

11-
To force that a value is simply not equal to ``null``, see the
11+
To force that a value is not equal to ``null``, see the
1212
:doc:`/reference/constraints/NotNull` constraint.
1313

1414
+----------------+------------------------------------------------------------------------+

security.rst

+5-6
Original file line numberDiff line numberDiff line change
@@ -452,7 +452,7 @@ this would deny you access. More on that later (:ref:`security-authorization-acc
452452
Loading Users from the Database
453453
...............................
454454

455-
If you'd like to load your users via the Doctrine ORM, that's easy! See
455+
If you'd like to load your users via the Doctrine ORM, see
456456
:doc:`/security/entity_provider` for all the details.
457457

458458
.. _security-encoding-user-password:
@@ -685,8 +685,7 @@ Add Code to Deny Access
685685
There are **two** ways to deny access to something:
686686

687687
#. :ref:`access_control in security.yml <security-authorization-access-control>`
688-
allows you to protect URL patterns (e.g. ``/admin/*``). This is easy,
689-
but less flexible;
688+
allows you to protect URL patterns (e.g. ``/admin/*``). Simpler, but less flexible;
690689

691690
#. :ref:`in your code via the security.authorization_checker service <security-securing-controller>`.
692691

@@ -808,8 +807,8 @@ matches the URL.
808807
]);
809808
810809
Prepending the path with ``^`` means that only URLs *beginning* with the
811-
pattern are matched. For example, a path of simply ``/admin`` (without
812-
the ``^``) would match ``/admin/foo`` but would also match URLs like ``/foo/admin``.
810+
pattern are matched. For example, a path of ``/admin`` (without the ``^``)
811+
would match ``/admin/foo`` but would also match URLs like ``/foo/admin``.
813812

814813
.. _security-access-control-explanation:
815814

@@ -828,7 +827,7 @@ the ``^``) would match ``/admin/foo`` but would also match URLs like ``/foo/admi
828827
Securing Controllers and other Code
829828
...................................
830829

831-
You can easily deny access from inside a controller::
830+
You can deny access from inside a controller::
832831

833832
// ...
834833

session/php_bridge.rst

+1-1
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ for the ``handler_id``:
4545
],
4646
]);
4747
48-
Otherwise, if the problem is simply that you cannot avoid the application
48+
Otherwise, if the problem is that you cannot avoid the application
4949
starting the session with ``session_start()``, you can still make use of
5050
a Symfony based session save handler by specifying the save handler as in
5151
the example below:

testing/profiling.rst

+1-1
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@ the ``test`` environment)::
5151

5252
If a test fails because of profiling data (too many DB queries for instance),
5353
you might want to use the Web Profiler to analyze the request after the tests
54-
finish. It's easy to achieve if you embed the token in the error message::
54+
finish. It can be achived by embedding the token in the error message::
5555

5656
$this->assertLessThan(
5757
30,

validation/raw_values.rst

+1-2
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,7 @@ How to Validate Raw Values (Scalar Values and Arrays)
66

77
Usually you will be validating entire objects. But sometimes, you just want
88
to validate a simple value - like to verify that a string is a valid email
9-
address. This is actually pretty easy to do. From inside a controller, it
10-
looks like this::
9+
address. From inside a controller, it looks like this::
1110

1211
// ...
1312
use Symfony\Component\Validator\Constraints as Assert;

validation/translations.rst

+2-2
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,8 @@
44
How to Translate Validation Constraint Messages
55
===============================================
66

7-
If you're using validation constraints with the Form component, then translating
8-
the error messages is easy: simply create a translation resource for the
7+
If you're using validation constraints with the Form component, you can translate
8+
the error messages by creating a translation resource for the
99
``validators`` :ref:`domain <using-message-domains>`.
1010

1111
To start, suppose you've created a plain-old-PHP object that you need to

0 commit comments

Comments
 (0)