Skip to content

Commit 4205d1a

Browse files
Merge pull request #32 from emmetog/patch-1
Add more detail to Usage section
2 parents 6535548 + a92048f commit 4205d1a

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

README.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,10 @@ please attach a copy of the error message and the relevant lines in ``app/cache/
4141

4242
## Usage
4343

44+
If you have an existing Symfony application and you want to ensure that the service definitions are always valid the easiest way is to add the compiler pass to your bundle as described [here](https://github.com/matthiasnoback/symfony-service-definition-validator#compiler-pass). That will validate your service definitions every time the bundle is compiled, which happens every single request if the cache is turned off (the default in debug mode).
45+
46+
If you want to validate the service definitions separately, like in a console command or in a test, you'll need to set it up yourself as described [here](https://github.com/matthiasnoback/symfony-service-definition-validator#service-validator-factory).
47+
4448
### Service validator factory
4549

4650
You can use the stand-alone validator for single definitions:

0 commit comments

Comments
 (0)