GitHub PullRequestReviewCommentEvent at 2014-11-05 09:03:26
Repository: symfony-docs
Actor: WouterJ
Payload: {"action":"created","comment":{"url":"https://api.github.com/repos/symfony/symfony-docs/pulls/comments/19861159","id":19861159,"diff_hunk":"@@ -0,0 +1,216 @@\n+.. index::\n+   single: VarDumper\n+   single: Components; VarDumper\n+\n+The VarDumper Component\n+=======================\n+\n+    The VarDumper component provides mechanisms for walking through any\n+    arbitrary PHP variable. Built on top, it provides a better ``dump()``\n+    function that you can use instead of :phpfunction:`var_dump`.\n+\n+.. versionadded:: 2.6\n+    The VarDumper component was introduced in Symfony 2.6.\n+\n+Installation\n+------------\n+\n+You can install the component in 2 different ways:\n+\n+* :doc:`Install it via Composer </components/using_components>` (``symfony/var-dumper`` on `Packagist`_);\n+* Use the official Git repository (https://github.com/symfony/var-dumper).\n+\n+The dump() Function\n+-------------------\n+\n+The VarDumper component creates a global ``dump()`` function that you can\n+use instead of e.g. :phpfunction:`var_dump`. By using it, you'll gain:\n+\n+* Per object and resource types specialized view to e.g. filter out\n+  Doctrine internals while dumping a single proxy entity, or get more\n+  insight on opened files with :phpfunction:`stream_get_meta_data()`;\n+* Configurable output formats: HTML or colored command line output;\n+* Ability to dump internal references, either soft ones (objects or\n+  resources) or hard ones (``=&`` on arrays or objects properties).\n+  Repeated occurrences of the same object/array/resource won't appear\n+  again and again anymore. Moreover, you'll be able to inspect the\n+  reference structure of your data;\n+* Ability to operate in the context of an output buffering handler.\n+\n+``dump()`` is just a thin wrapper and a more convenient way to call\n+:method:`VarDumper::dump() <Symfony\\\\Component\\\\VarDumper\\\\VarDumper::dump>`.\n+You can change the behavior of this function by calling\n+:method:`VarDumper::setHandler($callable) <Symfony\\\\Component\\\\VarDumper\\\\VarDumper::setHandler>`:\n+calls to ``dump()`` will then be forwarded to ``$callable``.\n+\n+By default, the output format and destination are selected based on your\n+current PHP SAPI:\n+\n+* On the command line (CLI SAPI), the output is written on ``STDOUT``. This\n+  can be surprising to some because this bypasses PHP's output buffering\n+  mechanism;\n+* On other SAPIs, dumps are written as HTML on the regular output.\n+\n+.. note::\n+    If you want to catch the dump output as a string, please read the\n+    `advanced documentation <advanced>` which contains examples of it.\n+    You'll also learn how to change the format or redirect the output to\n+    wherever you want.\n+\n+DebugBundle and Twig Integration\n+--------------------------------\n+\n+The ``DebugBundle`` allows greater integration of the component into the\n+Symfony full stack framework. It is enabled by default in the dev\n+environement of the standard edition since version 2.6.\n+\n+Since generating (even debug) output in the controller or in the model\n+of your application may just break it by e.g. sending HTTP headers or\n+corrupting your view, the bundle configures the ``dump()`` function so that\n+variables are dumped in the web debug toolbar.\n+\n+But if the toolbar can not be displayed because you e.g. called ``die``/``exit``\n+or a fatal error occurred, then dumps are written on the regular output.\n+\n+In a Twig template, two constructs are available for dumping a variable.\n+Choosing between both is mostly a matter of personal taste, still:\n+\n+* ``{% dump foo.bar %}`` is the way to go when the original template output\n+  shall not be modified: variables are not dumped inline, but in the web\n+  debug toolbar;\n+* on the contrary, ``{{ dump(foo.bar) }}`` dumps inline and thus may or not\n+  be suited to your use case (e.g. you shouldn't use it in an HTML\n+  attribute or a ``<script>`` tag).\n+\n+By default for nested variables, dumps are limited to a subset of their\n+original value. You can configure the limits in terms of:\n+\n+* maximum number of items to dump,\n+* maximum string length before truncation.\n+\n+.. configuration-block::\n+\n+    .. code-block:: yaml\n+\n+        debug:\n+           max_items: 250\n+           max_string_length: -1\n+\n+    .. code-block:: xml\n+\n+        <?xml version=\"1.0\" encoding=\"UTF-8\" ?>\n+        <container xmlns=\"http://symfony.com/schema/dic/debug\"\n+            xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-instance\"\n+            xsi:schemaLocation=\"http://symfony.com/schema/dic/debug http://symfony.com/schema/dic/debug/debug-1.0.xsd\">\n+\n+            <config max-items=\"250\" max-string-length=\"-1\" />\n+        </container>","path":"components/var_dumper/introduction.rst","position":107,"original_position":107,"commit_id":"b68f1bb801ee4f61485ece8a8acb7b17061a4989","original_commit_id":"b68f1bb801ee4f61485ece8a8acb7b17061a4989","user":{"login":"WouterJ","id":749025,"avatar_url":"https://avatars.githubusercontent.com/u/749025?v=2","gravatar_id":"","url":"https://api.github.com/users/WouterJ","html_url":"https://github.com/WouterJ","followers_url":"https://api.github.com/users/WouterJ/followers","following_url":"https://api.github.com/users/WouterJ/following{/other_user}","gists_url":"https://api.github.com/users/WouterJ/gists{/gist_id}","starred_url":"https://api.github.com/users/WouterJ/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/WouterJ/subscriptions","organizations_url":"https://api.github.com/users/WouterJ/orgs","repos_url":"https://api.github.com/users/WouterJ/repos","events_url":"https://api.github.com/users/WouterJ/events{/privacy}","received_events_url":"https://api.github.com/users/WouterJ/received_events","type":"User","site_admin":false},"body":"since this is the components, configuration like this isn't available (this is about the bundle). We should document  ``setMaxItems`` and ``setMaxString`` instead. However, there might be a better location then here. We should give a user examples first and then talk about all customization imo","created_at":"2014-11-05T09:03:26Z","updated_at":"2014-11-05T09:03:26Z","html_url":"https://github.com/symfony/symfony-docs/pull/4243#discussion_r19861159","pull_request_url":"https://api.github.com/repos/symfony/symfony-docs/pulls/4243","_links":{"self":{"href":"https://api.github.com/repos/symfony/symfony-docs/pulls/comments/19861159"},"html":{"href":"https://github.com/symfony/symfony-docs/pull/4243#discussion_r19861159"},"pull_request":{"href":"https://api.github.com/repos/symfony/symfony-docs/pulls/4243"}}},"pull_request":{"url":"https://api.github.com/repos/symfony/symfony-docs/pulls/4243","id":21380405,"html_url":"https://github.com/symfony/symfony-docs/pull/4243","diff_url":"https://github.com/symfony/symfony-docs/pull/4243.diff","patch_url":"https://github.com/symfony/symfony-docs/pull/4243.patch","issue_url":"https://api.github.com/repos/symfony/symfony-docs/issues/4243","number":4243,"state":"open","locked":false,"title":"[WIP] var-dumper component","user":{"login":"nicolas-grekas","id":243674,"avatar_url":"https://avatars.githubusercontent.com/u/243674?v=2","gravatar_id":"","url":"https://api.github.com/users/nicolas-grekas","html_url":"https://github.com/nicolas-grekas","followers_url":"https://api.github.com/users/nicolas-grekas/followers","following_url":"https://api.github.com/users/nicolas-grekas/following{/other_user}","gists_url":"https://api.github.com/users/nicolas-grekas/gists{/gist_id}","starred_url":"https://api.github.com/users/nicolas-grekas/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/nicolas-grekas/subscriptions","organizations_url":"https://api.github.com/users/nicolas-grekas/orgs","repos_url":"https://api.github.com/users/nicolas-grekas/repos","events_url":"https://api.github.com/users/nicolas-grekas/events{/privacy}","received_events_url":"https://api.github.com/users/nicolas-grekas/received_events","type":"User","site_admin":false},"body":"| Q             | A\r\n| ------------- | ---\r\n| Doc fix?      | no\r\n| New docs?     | yes\r\n| Applies to    | 2.6\r\n| Fixed tickets | none\r\n\r\n- [x] general introduction\r\n- [x] cloner doc\r\n- [x] caster doc\r\n- [x] dumper doc\r\n- [x] config doc\r\n- [x] example output with explanations\r\n","created_at":"2014-09-17T16:56:52Z","updated_at":"2014-11-05T09:03:26Z","closed_at":null,"merged_at":null,"merge_commit_sha":"2f22106b8e7453636aabdfb11a826e5094c6b66a","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/symfony/symfony-docs/pulls/4243/commits","review_comments_url":"https://api.github.com/repos/symfony/symfony-docs/pulls/4243/comments","review_comment_url":"https://api.github.com/repos/symfony/symfony-docs/pulls/comments/{number}","comments_url":"https://api.github.com/repos/symfony/symfony-docs/issues/4243/comments","statuses_url":"https://api.github.com/repos/symfony/symfony-docs/statuses/b68f1bb801ee4f61485ece8a8acb7b17061a4989","head":{"label":"nicolas-grekas:var-dumper","ref":"var-dumper","sha":"b68f1bb801ee4f61485ece8a8acb7b17061a4989","user":{"login":"nicolas-grekas","id":243674,"avatar_url":"https://avatars.githubusercontent.com/u/243674?v=2","gravatar_id":"","url":"https://api.github.com/users/nicolas-grekas","html_url":"https://github.com/nicolas-grekas","followers_url":"https://api.github.com/users/nicolas-grekas/followers","following_url":"https://api.github.com/users/nicolas-grekas/following{/other_user}","gists_url":"https://api.github.com/users/nicolas-grekas/gists{/gist_id}","starred_url":"https://api.github.com/users/nicolas-grekas/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/nicolas-grekas/subscriptions","organizations_url":"https://api.github.com/users/nicolas-grekas/orgs","repos_url":"https://api.github.com/users/nicolas-grekas/repos","events_url":"https://api.github.com/users/nicolas-grekas/events{/privacy}","received_events_url":"https://api.github.com/users/nicolas-grekas/received_events","type":"User","site_admin":false},"repo":{"id":19969223,"name":"symfony-docs","full_name":"nicolas-grekas/symfony-docs","owner":{"login":"nicolas-grekas","id":243674,"avatar_url":"https://avatars.githubusercontent.com/u/243674?v=2","gravatar_id":"","url":"https://api.github.com/users/nicolas-grekas","html_url":"https://github.com/nicolas-grekas","followers_url":"https://api.github.com/users/nicolas-grekas/followers","following_url":"https://api.github.com/users/nicolas-grekas/following{/other_user}","gists_url":"https://api.github.com/users/nicolas-grekas/gists{/gist_id}","starred_url":"https://api.github.com/users/nicolas-grekas/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/nicolas-grekas/subscriptions","organizations_url":"https://api.github.com/users/nicolas-grekas/orgs","repos_url":"https://api.github.com/users/nicolas-grekas/repos","events_url":"https://api.github.com/users/nicolas-grekas/events{/privacy}","received_events_url":"https://api.github.com/users/nicolas-grekas/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/nicolas-grekas/symfony-docs","description":"The Symfony2 documentation","fork":true,"url":"https://api.github.com/repos/nicolas-grekas/symfony-docs","forks_url":"https://api.github.com/repos/nicolas-grekas/symfony-docs/forks","keys_url":"https://api.github.com/repos/nicolas-grekas/symfony-docs/keys{/key_id}","collaborators_url":"https://api.github.com/repos/nicolas-grekas/symfony-docs/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/nicolas-grekas/symfony-docs/teams","hooks_url":"https://api.github.com/repos/nicolas-grekas/symfony-docs/hooks","issue_events_url":"https://api.github.com/repos/nicolas-grekas/symfony-docs/issues/events{/number}","events_url":"https://api.github.com/repos/nicolas-grekas/symfony-docs/events","assignees_url":"https://api.github.com/repos/nicolas-grekas/symfony-docs/assignees{/user}","branches_url":"https://api.github.com/repos/nicolas-grekas/symfony-docs/branches{/branch}","tags_url":"https://api.github.com/repos/nicolas-grekas/symfony-docs/tags","blobs_url":"https://api.github.com/repos/nicolas-grekas/symfony-docs/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/nicolas-grekas/symfony-docs/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/nicolas-grekas/symfony-docs/git/refs{/sha}","trees_url":"https://api.github.com/repos/nicolas-grekas/symfony-docs/git/trees{/sha}","statuses_url":"https://api.github.com/repos/nicolas-grekas/symfony-docs/statuses/{sha}","languages_url":"https://api.github.com/repos/nicolas-grekas/symfony-docs/languages","stargazers_url":"https://api.github.com/repos/nicolas-grekas/symfony-docs/stargazers","contributors_url":"https://api.github.com/repos/nicolas-grekas/symfony-docs/contributors","subscribers_url":"https://api.github.com/repos/nicolas-grekas/symfony-docs/subscribers","subscription_url":"https://api.github.com/repos/nicolas-grekas/symfony-docs/subscription","commits_url":"https://api.github.com/repos/nicolas-grekas/symfony-docs/commits{/sha}","git_commits_url":"https://api.github.com/repos/nicolas-grekas/symfony-docs/git/commits{/sha}","comments_url":"https://api.github.com/repos/nicolas-grekas/symfony-docs/comments{/number}","issue_comment_url":"https://api.github.com/repos/nicolas-grekas/symfony-docs/issues/comments/{number}","contents_url":"https://api.github.com/repos/nicolas-grekas/symfony-docs/contents/{+path}","compare_url":"https://api.github.com/repos/nicolas-grekas/symfony-docs/compare/{base}...{head}","merges_url":"https://api.github.com/repos/nicolas-grekas/symfony-docs/merges","archive_url":"https://api.github.com/repos/nicolas-grekas/symfony-docs/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/nicolas-grekas/symfony-docs/downloads","issues_url":"https://api.github.com/repos/nicolas-grekas/symfony-docs/issues{/number}","pulls_url":"https://api.github.com/repos/nicolas-grekas/symfony-docs/pulls{/number}","milestones_url":"https://api.github.com/repos/nicolas-grekas/symfony-docs/milestones{/number}","notifications_url":"https://api.github.com/repos/nicolas-grekas/symfony-docs/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/nicolas-grekas/symfony-docs/labels{/name}","releases_url":"https://api.github.com/repos/nicolas-grekas/symfony-docs/releases{/id}","created_at":"2014-05-20T05:52:44Z","updated_at":"2014-09-17T11:01:30Z","pushed_at":"2014-11-05T08:50:54Z","git_url":"git://github.com/nicolas-grekas/symfony-docs.git","ssh_url":"git@github.com:nicolas-grekas/symfony-docs.git","clone_url":"https://github.com/nicolas-grekas/symfony-docs.git","svn_url":"https://github.com/nicolas-grekas/symfony-docs","homepage":"http://symfony.com/doc/current/","size":22204,"stargazers_count":0,"watchers_count":0,"language":"Python","has_issues":false,"has_downloads":false,"has_wiki":false,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"symfony:master","ref":"master","sha":"5d43069e0821123cf4499ce1f0072957a941b0dc","user":{"login":"symfony","id":143937,"avatar_url":"https://avatars.githubusercontent.com/u/143937?v=2","gravatar_id":"","url":"https://api.github.com/users/symfony","html_url":"https://github.com/symfony","followers_url":"https://api.github.com/users/symfony/followers","following_url":"https://api.github.com/users/symfony/following{/other_user}","gists_url":"https://api.github.com/users/symfony/gists{/gist_id}","starred_url":"https://api.github.com/users/symfony/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/symfony/subscriptions","organizations_url":"https://api.github.com/users/symfony/orgs","repos_url":"https://api.github.com/users/symfony/repos","events_url":"https://api.github.com/users/symfony/events{/privacy}","received_events_url":"https://api.github.com/users/symfony/received_events","type":"Organization","site_admin":false},"repo":{"id":521583,"name":"symfony-docs","full_name":"symfony/symfony-docs","owner":{"login":"symfony","id":143937,"avatar_url":"https://avatars.githubusercontent.com/u/143937?v=2","gravatar_id":"","url":"https://api.github.com/users/symfony","html_url":"https://github.com/symfony","followers_url":"https://api.github.com/users/symfony/followers","following_url":"https://api.github.com/users/symfony/following{/other_user}","gists_url":"https://api.github.com/users/symfony/gists{/gist_id}","starred_url":"https://api.github.com/users/symfony/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/symfony/subscriptions","organizations_url":"https://api.github.com/users/symfony/orgs","repos_url":"https://api.github.com/users/symfony/repos","events_url":"https://api.github.com/users/symfony/events{/privacy}","received_events_url":"https://api.github.com/users/symfony/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/symfony/symfony-docs","description":"The Symfony2 documentation","fork":false,"url":"https://api.github.com/repos/symfony/symfony-docs","forks_url":"https://api.github.com/repos/symfony/symfony-docs/forks","keys_url":"https://api.github.com/repos/symfony/symfony-docs/keys{/key_id}","collaborators_url":"https://api.github.com/repos/symfony/symfony-docs/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/symfony/symfony-docs/teams","hooks_url":"https://api.github.com/repos/symfony/symfony-docs/hooks","issue_events_url":"https://api.github.com/repos/symfony/symfony-docs/issues/events{/number}","events_url":"https://api.github.com/repos/symfony/symfony-docs/events","assignees_url":"https://api.github.com/repos/symfony/symfony-docs/assignees{/user}","branches_url":"https://api.github.com/repos/symfony/symfony-docs/branches{/branch}","tags_url":"https://api.github.com/repos/symfony/symfony-docs/tags","blobs_url":"https://api.github.com/repos/symfony/symfony-docs/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/symfony/symfony-docs/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/symfony/symfony-docs/git/refs{/sha}","trees_url":"https://api.github.com/repos/symfony/symfony-docs/git/trees{/sha}","statuses_url":"https://api.github.com/repos/symfony/symfony-docs/statuses/{sha}","languages_url":"https://api.github.com/repos/symfony/symfony-docs/languages","stargazers_url":"https://api.github.com/repos/symfony/symfony-docs/stargazers","contributors_url":"https://api.github.com/repos/symfony/symfony-docs/contributors","subscribers_url":"https://api.github.com/repos/symfony/symfony-docs/subscribers","subscription_url":"https://api.github.com/repos/symfony/symfony-docs/subscription","commits_url":"https://api.github.com/repos/symfony/symfony-docs/commits{/sha}","git_commits_url":"https://api.github.com/repos/symfony/symfony-docs/git/commits{/sha}","comments_url":"https://api.github.com/repos/symfony/symfony-docs/comments{/number}","issue_comment_url":"https://api.github.com/repos/symfony/symfony-docs/issues/comments/{number}","contents_url":"https://api.github.com/repos/symfony/symfony-docs/contents/{+path}","compare_url":"https://api.github.com/repos/symfony/symfony-docs/compare/{base}...{head}","merges_url":"https://api.github.com/repos/symfony/symfony-docs/merges","archive_url":"https://api.github.com/repos/symfony/symfony-docs/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/symfony/symfony-docs/downloads","issues_url":"https://api.github.com/repos/symfony/symfony-docs/issues{/number}","pulls_url":"https://api.github.com/repos/symfony/symfony-docs/pulls{/number}","milestones_url":"https://api.github.com/repos/symfony/symfony-docs/milestones{/number}","notifications_url":"https://api.github.com/repos/symfony/symfony-docs/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/symfony/symfony-docs/labels{/name}","releases_url":"https://api.github.com/repos/symfony/symfony-docs/releases{/id}","created_at":"2010-02-17T08:43:51Z","updated_at":"2014-11-03T08:45:48Z","pushed_at":"2014-11-04T15:03:34Z","git_url":"git://github.com/symfony/symfony-docs.git","ssh_url":"git@github.com:symfony/symfony-docs.git","clone_url":"https://github.com/symfony/symfony-docs.git","svn_url":"https://github.com/symfony/symfony-docs","homepage":"http://symfony.com/doc/current/","size":55834,"stargazers_count":931,"watchers_count":931,"language":"Assembly","has_issues":true,"has_downloads":false,"has_wiki":false,"has_pages":false,"forks_count":1508,"mirror_url":null,"open_issues_count":229,"forks":1508,"open_issues":229,"watchers":931,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/symfony/symfony-docs/pulls/4243"},"html":{"href":"https://github.com/symfony/symfony-docs/pull/4243"},"issue":{"href":"https://api.github.com/repos/symfony/symfony-docs/issues/4243"},"comments":{"href":"https://api.github.com/repos/symfony/symfony-docs/issues/4243/comments"},"review_comments":{"href":"https://api.github.com/repos/symfony/symfony-docs/pulls/4243/comments"},"review_comment":{"href":"https://api.github.com/repos/symfony/symfony-docs/pulls/comments/{number}"},"commits":{"href":"https://api.github.com/repos/symfony/symfony-docs/pulls/4243/commits"},"statuses":{"href":"https://api.github.com/repos/symfony/symfony-docs/statuses/b68f1bb801ee4f61485ece8a8acb7b17061a4989"}}}}