This repository was archived by the owner on Dec 9, 2023. It is now read-only.
File tree Expand file tree Collapse file tree 1 file changed +6
-37
lines changed Expand file tree Collapse file tree 1 file changed +6
-37
lines changed Original file line number Diff line number Diff line change 1
1
Debug Component
2
2
===============
3
3
4
- Debug provides tools to make debugging easier.
5
-
6
- Enabling all debug tools is as easy as calling the ` enable() ` method on the
7
- main ` Debug ` class:
8
-
9
- ``` php
10
- use Symfony\Component\Debug\Debug;
11
-
12
- Debug::enable();
13
- ```
14
-
15
- You can also use the tools individually:
16
-
17
- ``` php
18
- use Symfony\Component\Debug\ErrorHandler;
19
- use Symfony\Component\Debug\ExceptionHandler;
20
-
21
- error_reporting(-1);
22
-
23
- ErrorHandler::register($errorReportingLevel);
24
- if ('cli' !== php_sapi_name()) {
25
- ExceptionHandler::register();
26
- } elseif (!ini_get('log_errors') || ini_get('error_log')) {
27
- ini_set('display_errors', 1);
28
- }
29
- ```
30
-
31
- Note that the ` Debug::enable() ` call also registers the debug class loader
32
- from the Symfony ClassLoader component when available.
33
-
34
- This component can optionally take advantage of the features of the HttpKernel
35
- and HttpFoundation components.
4
+ The Debug component provides tools to ease debugging PHP code.
36
5
37
6
Resources
38
7
---------
39
8
40
- You can run the unit tests with the following command:
41
-
42
- $ cd path/to/Symfony/Component/Debug/
43
- $ composer install
44
- $ phpunit
9
+ * [ Documentation ] ( https://symfony.com/doc/current/components/debug/index.html )
10
+ * [ Contributing ] ( https://symfony.com/doc/current/contributing/index.html )
11
+ * [ Report issues ] ( https://github.com/symfony/symfony/issues ) and
12
+ [ send Pull Requests ] ( https://github.com/symfony/symfony/pulls )
13
+ in the [ main Symfony repository ] ( https://github.com/symfony/symfony )
You can’t perform that action at this time.
0 commit comments