debugbar.php 7.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201
  1. <?php
  2. return [
  3. /*
  4. |--------------------------------------------------------------------------
  5. | Debugbar Settings
  6. |--------------------------------------------------------------------------
  7. |
  8. | Debugbar is enabled by default, when debug is set to true in app.php.
  9. | You can override the value by setting enable to true or false instead of null.
  10. |
  11. | You can provide an array of URI's that must be ignored (eg. 'api/*')
  12. |
  13. */
  14. 'enabled' => env('DEBUGBAR_ENABLED', null),
  15. 'except' => [
  16. 'telescope*'
  17. ],
  18. /*
  19. |--------------------------------------------------------------------------
  20. | Storage settings
  21. |--------------------------------------------------------------------------
  22. |
  23. | DebugBar stores data for session/ajax requests.
  24. | You can disable this, so the debugbar stores data in headers/session,
  25. | but this can cause problems with large data collectors.
  26. | By default, file storage (in the storage folder) is used. Redis and PDO
  27. | can also be used. For PDO, run the package migrations first.
  28. |
  29. */
  30. 'storage' => [
  31. 'enabled' => true,
  32. 'driver' => 'file', // redis, file, pdo, custom
  33. 'path' => storage_path('debugbar'), // For file driver
  34. 'connection' => null, // Leave null for default connection (Redis/PDO)
  35. 'provider' => '' // Instance of StorageInterface for custom driver
  36. ],
  37. /*
  38. |--------------------------------------------------------------------------
  39. | Vendors
  40. |--------------------------------------------------------------------------
  41. |
  42. | Vendor files are included by default, but can be set to false.
  43. | This can also be set to 'js' or 'css', to only include javascript or css vendor files.
  44. | Vendor files are for css: font-awesome (including fonts) and highlight.js (css files)
  45. | and for js: jquery and and highlight.js
  46. | So if you want syntax highlighting, set it to true.
  47. | jQuery is set to not conflict with existing jQuery scripts.
  48. |
  49. */
  50. 'include_vendors' => true,
  51. /*
  52. |--------------------------------------------------------------------------
  53. | Capture Ajax Requests
  54. |--------------------------------------------------------------------------
  55. |
  56. | The Debugbar can capture Ajax requests and display them. If you don't want this (ie. because of errors),
  57. | you can use this option to disable sending the data through the headers.
  58. |
  59. | Optionally, you can also send ServerTiming headers on ajax requests for the Chrome DevTools.
  60. */
  61. 'capture_ajax' => true,
  62. 'add_ajax_timing' => false,
  63. /*
  64. |--------------------------------------------------------------------------
  65. | Custom Error Handler for Deprecated warnings
  66. |--------------------------------------------------------------------------
  67. |
  68. | When enabled, the Debugbar shows deprecated warnings for Symfony components
  69. | in the Messages tab.
  70. |
  71. */
  72. 'error_handler' => false,
  73. /*
  74. |--------------------------------------------------------------------------
  75. | Clockwork integration
  76. |--------------------------------------------------------------------------
  77. |
  78. | The Debugbar can emulate the Clockwork headers, so you can use the Chrome
  79. | Extension, without the server-side code. It uses Debugbar collectors instead.
  80. |
  81. */
  82. 'clockwork' => false,
  83. /*
  84. |--------------------------------------------------------------------------
  85. | DataCollectors
  86. |--------------------------------------------------------------------------
  87. |
  88. | Enable/disable DataCollectors
  89. |
  90. */
  91. 'collectors' => [
  92. 'phpinfo' => true, // Php version
  93. 'messages' => true, // Messages
  94. 'time' => true, // Time Datalogger
  95. 'memory' => true, // Memory usage
  96. 'exceptions' => true, // Exception displayer
  97. 'log' => true, // Logs from Monolog (merged in messages if enabled)
  98. 'db' => true, // Show database (PDO) queries and bindings
  99. 'views' => true, // Views with their data
  100. 'route' => true, // Current route information
  101. 'auth' => true, // Display Laravel authentication status
  102. 'gate' => true, // Display Laravel Gate checks
  103. 'session' => true, // Display session data
  104. 'symfony_request' => true, // Only one can be enabled..
  105. 'mail' => true, // Catch mail messages
  106. 'laravel' => false, // Laravel version and environment
  107. 'events' => false, // All events fired
  108. 'default_request' => false, // Regular or special Symfony request logger
  109. 'logs' => false, // Add the latest log messages
  110. 'files' => false, // Show the included files
  111. 'config' => false, // Display config settings
  112. 'cache' => false, // Display cache events
  113. ],
  114. /*
  115. |--------------------------------------------------------------------------
  116. | Extra options
  117. |--------------------------------------------------------------------------
  118. |
  119. | Configure some DataCollectors
  120. |
  121. */
  122. 'options' => [
  123. 'auth' => [
  124. 'show_name' => true, // Also show the users name/email in the debugbar
  125. ],
  126. 'db' => [
  127. 'with_params' => true, // Render SQL with the parameters substituted
  128. 'backtrace' => true, // Use a backtrace to find the origin of the query in your files.
  129. 'timeline' => false, // Add the queries to the timeline
  130. 'explain' => [ // Show EXPLAIN output on queries
  131. 'enabled' => false,
  132. 'types' => ['SELECT'], // // workaround ['SELECT'] only. https://github.com/barryvdh/laravel-debugbar/issues/888 ['SELECT', 'INSERT', 'UPDATE', 'DELETE']; for MySQL 5.6.3+
  133. ],
  134. 'hints' => true, // Show hints for common mistakes
  135. ],
  136. 'mail' => [
  137. 'full_log' => false
  138. ],
  139. 'views' => [
  140. 'data' => false, //Note: Can slow down the application, because the data can be quite large..
  141. ],
  142. 'route' => [
  143. 'label' => true // show complete route on bar
  144. ],
  145. 'logs' => [
  146. 'file' => null
  147. ],
  148. 'cache' => [
  149. 'values' => true // collect cache values
  150. ],
  151. ],
  152. /*
  153. |--------------------------------------------------------------------------
  154. | Inject Debugbar in Response
  155. |--------------------------------------------------------------------------
  156. |
  157. | Usually, the debugbar is added just before </body>, by listening to the
  158. | Response after the App is done. If you disable this, you have to add them
  159. | in your template yourself. See http://phpdebugbar.com/docs/rendering.html
  160. |
  161. */
  162. 'inject' => true,
  163. /*
  164. |--------------------------------------------------------------------------
  165. | DebugBar route prefix
  166. |--------------------------------------------------------------------------
  167. |
  168. | Sometimes you want to set route prefix to be used by DebugBar to load
  169. | its resources from. Usually the need comes from misconfigured web server or
  170. | from trying to overcome bugs like this: http://trac.nginx.org/nginx/ticket/97
  171. |
  172. */
  173. 'route_prefix' => '_debugbar',
  174. /*
  175. |--------------------------------------------------------------------------
  176. | DebugBar route domain
  177. |--------------------------------------------------------------------------
  178. |
  179. | By default DebugBar route served from the same domain that request served.
  180. | To override default domain, specify it as a non-empty value.
  181. */
  182. 'route_domain' => null,
  183. ];