{"action":"created","comment":{"url":"https://api.github.com/repos/mdx-js/mdx/pulls/comments/217171861","pull_request_review_id":154822876,"id":217171861,"node_id":"MDI0OlB1bGxSZXF1ZXN0UmV2aWV3Q29tbWVudDIxNzE3MTg2MQ==","diff_hunk":"@@ -18,6 +20,38 @@ module.exports = function mdxAstToMdxHast() {\n           ]\n         })\n       },\n+      code(h, node) {\n+        var value = node.value ? detab(node.value + '\\n') : ''","path":"packages/mdx/mdx-ast-to-mdx-hast.js","position":12,"original_position":12,"commit_id":"2442104b9315af934357800e0a7e6a8c68355bab","original_commit_id":"2442104b9315af934357800e0a7e6a8c68355bab","user":{"login":"johno","id":1424573,"node_id":"MDQ6VXNlcjE0MjQ1NzM=","avatar_url":"https://avatars2.githubusercontent.com/u/1424573?v=4","gravatar_id":"","url":"https://api.github.com/users/johno","html_url":"https://github.com/johno","followers_url":"https://api.github.com/users/johno/followers","following_url":"https://api.github.com/users/johno/following{/other_user}","gists_url":"https://api.github.com/users/johno/gists{/gist_id}","starred_url":"https://api.github.com/users/johno/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/johno/subscriptions","organizations_url":"https://api.github.com/users/johno/orgs","repos_url":"https://api.github.com/users/johno/repos","events_url":"https://api.github.com/users/johno/events{/privacy}","received_events_url":"https://api.github.com/users/johno/received_events","type":"User","site_admin":false},"body":"Can we use `const` here?","created_at":"2018-09-12T20:10:47Z","updated_at":"2018-09-12T20:16:15Z","html_url":"https://github.com/mdx-js/mdx/pull/257#discussion_r217171861","pull_request_url":"https://api.github.com/repos/mdx-js/mdx/pulls/257","author_association":"MEMBER","_links":{"self":{"href":"https://api.github.com/repos/mdx-js/mdx/pulls/comments/217171861"},"html":{"href":"https://github.com/mdx-js/mdx/pull/257#discussion_r217171861"},"pull_request":{"href":"https://api.github.com/repos/mdx-js/mdx/pulls/257"}}},"pull_request":{"url":"https://api.github.com/repos/mdx-js/mdx/pulls/257","id":215062952,"node_id":"MDExOlB1bGxSZXF1ZXN0MjE1MDYyOTUy","html_url":"https://github.com/mdx-js/mdx/pull/257","diff_url":"https://github.com/mdx-js/mdx/pull/257.diff","patch_url":"https://github.com/mdx-js/mdx/pull/257.patch","issue_url":"https://api.github.com/repos/mdx-js/mdx/issues/257","number":257,"state":"open","locked":false,"title":"enable infostring props","user":{"login":"ChristopherBiscardi","id":551247,"node_id":"MDQ6VXNlcjU1MTI0Nw==","avatar_url":"https://avatars1.githubusercontent.com/u/551247?v=4","gravatar_id":"","url":"https://api.github.com/users/ChristopherBiscardi","html_url":"https://github.com/ChristopherBiscardi","followers_url":"https://api.github.com/users/ChristopherBiscardi/followers","following_url":"https://api.github.com/users/ChristopherBiscardi/following{/other_user}","gists_url":"https://api.github.com/users/ChristopherBiscardi/gists{/gist_id}","starred_url":"https://api.github.com/users/ChristopherBiscardi/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ChristopherBiscardi/subscriptions","organizations_url":"https://api.github.com/users/ChristopherBiscardi/orgs","repos_url":"https://api.github.com/users/ChristopherBiscardi/repos","events_url":"https://api.github.com/users/ChristopherBiscardi/events{/privacy}","received_events_url":"https://api.github.com/users/ChristopherBiscardi/received_events","type":"User","site_admin":false},"body":"This PR enables the passing of the full infostring content as props to react components, enabling things like repls to be enabled as such:\r\n\r\n![carbon 2](https://user-images.githubusercontent.com/551247/45446852-c7ddb680-b682-11e8-89a4-124fe2be3572.png)\r\n\r\n\r\nThe PR mostly copies from the underlying [mdast handler](https://github.com/syntax-tree/mdast-util-to-hast/blob/1f8591e0b6163c437999e842774f66c9027cfc47/lib/handlers/code.js), but adds basic handling for potential meta strings. I think the handling is \"good enough\" right now even though it has some quirks like requiring a single space between infostring parameters. We can expand the algorithm in the future if things like array support are desired.\r\n\r\nbased on the conversation in https://github.com/syntax-tree/mdast-util-to-hast/issues/24\r\n\r\ncloses https://github.com/mdx-js/mdx/issues/141 and https://github.com/ChristopherBiscardi/gatsby-mdx/issues/76","created_at":"2018-09-12T19:00:01Z","updated_at":"2018-09-12T20:16:15Z","closed_at":null,"merged_at":null,"merge_commit_sha":"ddd1b3edc7e8557ca0749659f08f0164a2f9d321","assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"labels":[],"milestone":null,"commits_url":"https://api.github.com/repos/mdx-js/mdx/pulls/257/commits","review_comments_url":"https://api.github.com/repos/mdx-js/mdx/pulls/257/comments","review_comment_url":"https://api.github.com/repos/mdx-js/mdx/pulls/comments{/number}","comments_url":"https://api.github.com/repos/mdx-js/mdx/issues/257/comments","statuses_url":"https://api.github.com/repos/mdx-js/mdx/statuses/2442104b9315af934357800e0a7e6a8c68355bab","head":{"label":"mdx-js:infostring-props","ref":"infostring-props","sha":"2442104b9315af934357800e0a7e6a8c68355bab","user":{"login":"mdx-js","id":37453691,"node_id":"MDEyOk9yZ2FuaXphdGlvbjM3NDUzNjkx","avatar_url":"https://avatars3.githubusercontent.com/u/37453691?v=4","gravatar_id":"","url":"https://api.github.com/users/mdx-js","html_url":"https://github.com/mdx-js","followers_url":"https://api.github.com/users/mdx-js/followers","following_url":"https://api.github.com/users/mdx-js/following{/other_user}","gists_url":"https://api.github.com/users/mdx-js/gists{/gist_id}","starred_url":"https://api.github.com/users/mdx-js/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mdx-js/subscriptions","organizations_url":"https://api.github.com/users/mdx-js/orgs","repos_url":"https://api.github.com/users/mdx-js/repos","events_url":"https://api.github.com/users/mdx-js/events{/privacy}","received_events_url":"https://api.github.com/users/mdx-js/received_events","type":"Organization","site_admin":false},"repo":{"id":115229134,"node_id":"MDEwOlJlcG9zaXRvcnkxMTUyMjkxMzQ=","name":"mdx","full_name":"mdx-js/mdx","owner":{"login":"mdx-js","id":37453691,"node_id":"MDEyOk9yZ2FuaXphdGlvbjM3NDUzNjkx","avatar_url":"https://avatars3.githubusercontent.com/u/37453691?v=4","gravatar_id":"","url":"https://api.github.com/users/mdx-js","html_url":"https://github.com/mdx-js","followers_url":"https://api.github.com/users/mdx-js/followers","following_url":"https://api.github.com/users/mdx-js/following{/other_user}","gists_url":"https://api.github.com/users/mdx-js/gists{/gist_id}","starred_url":"https://api.github.com/users/mdx-js/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mdx-js/subscriptions","organizations_url":"https://api.github.com/users/mdx-js/orgs","repos_url":"https://api.github.com/users/mdx-js/repos","events_url":"https://api.github.com/users/mdx-js/events{/privacy}","received_events_url":"https://api.github.com/users/mdx-js/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/mdx-js/mdx","description":"JSX in Markdown for ambitious projects","fork":false,"url":"https://api.github.com/repos/mdx-js/mdx","forks_url":"https://api.github.com/repos/mdx-js/mdx/forks","keys_url":"https://api.github.com/repos/mdx-js/mdx/keys{/key_id}","collaborators_url":"https://api.github.com/repos/mdx-js/mdx/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/mdx-js/mdx/teams","hooks_url":"https://api.github.com/repos/mdx-js/mdx/hooks","issue_events_url":"https://api.github.com/repos/mdx-js/mdx/issues/events{/number}","events_url":"https://api.github.com/repos/mdx-js/mdx/events","assignees_url":"https://api.github.com/repos/mdx-js/mdx/assignees{/user}","branches_url":"https://api.github.com/repos/mdx-js/mdx/branches{/branch}","tags_url":"https://api.github.com/repos/mdx-js/mdx/tags","blobs_url":"https://api.github.com/repos/mdx-js/mdx/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/mdx-js/mdx/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/mdx-js/mdx/git/refs{/sha}","trees_url":"https://api.github.com/repos/mdx-js/mdx/git/trees{/sha}","statuses_url":"https://api.github.com/repos/mdx-js/mdx/statuses/{sha}","languages_url":"https://api.github.com/repos/mdx-js/mdx/languages","stargazers_url":"https://api.github.com/repos/mdx-js/mdx/stargazers","contributors_url":"https://api.github.com/repos/mdx-js/mdx/contributors","subscribers_url":"https://api.github.com/repos/mdx-js/mdx/subscribers","subscription_url":"https://api.github.com/repos/mdx-js/mdx/subscription","commits_url":"https://api.github.com/repos/mdx-js/mdx/commits{/sha}","git_commits_url":"https://api.github.com/repos/mdx-js/mdx/git/commits{/sha}","comments_url":"https://api.github.com/repos/mdx-js/mdx/comments{/number}","issue_comment_url":"https://api.github.com/repos/mdx-js/mdx/issues/comments{/number}","contents_url":"https://api.github.com/repos/mdx-js/mdx/contents/{+path}","compare_url":"https://api.github.com/repos/mdx-js/mdx/compare/{base}...{head}","merges_url":"https://api.github.com/repos/mdx-js/mdx/merges","archive_url":"https://api.github.com/repos/mdx-js/mdx/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/mdx-js/mdx/downloads","issues_url":"https://api.github.com/repos/mdx-js/mdx/issues{/number}","pulls_url":"https://api.github.com/repos/mdx-js/mdx/pulls{/number}","milestones_url":"https://api.github.com/repos/mdx-js/mdx/milestones{/number}","notifications_url":"https://api.github.com/repos/mdx-js/mdx/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/mdx-js/mdx/labels{/name}","releases_url":"https://api.github.com/repos/mdx-js/mdx/releases{/id}","deployments_url":"https://api.github.com/repos/mdx-js/mdx/deployments","created_at":"2017-12-24T00:01:48Z","updated_at":"2018-09-12T19:55:56Z","pushed_at":"2018-09-12T19:00:02Z","git_url":"git://github.com/mdx-js/mdx.git","ssh_url":"git@github.com:mdx-js/mdx.git","clone_url":"https://github.com/mdx-js/mdx.git","svn_url":"https://github.com/mdx-js/mdx","homepage":"https://mdxjs.com","size":954,"stargazers_count":3919,"watchers_count":3919,"language":"JavaScript","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":120,"mirror_url":null,"archived":false,"open_issues_count":46,"license":{"key":"mit","name":"MIT License","spdx_id":"MIT","url":"https://api.github.com/licenses/mit","node_id":"MDc6TGljZW5zZTEz"},"forks":120,"open_issues":46,"watchers":3919,"default_branch":"master"}},"base":{"label":"mdx-js:master","ref":"master","sha":"3499af28b3d0cf5f7f8e8ffe47ab8f17c87ff9fa","user":{"login":"mdx-js","id":37453691,"node_id":"MDEyOk9yZ2FuaXphdGlvbjM3NDUzNjkx","avatar_url":"https://avatars3.githubusercontent.com/u/37453691?v=4","gravatar_id":"","url":"https://api.github.com/users/mdx-js","html_url":"https://github.com/mdx-js","followers_url":"https://api.github.com/users/mdx-js/followers","following_url":"https://api.github.com/users/mdx-js/following{/other_user}","gists_url":"https://api.github.com/users/mdx-js/gists{/gist_id}","starred_url":"https://api.github.com/users/mdx-js/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mdx-js/subscriptions","organizations_url":"https://api.github.com/users/mdx-js/orgs","repos_url":"https://api.github.com/users/mdx-js/repos","events_url":"https://api.github.com/users/mdx-js/events{/privacy}","received_events_url":"https://api.github.com/users/mdx-js/received_events","type":"Organization","site_admin":false},"repo":{"id":115229134,"node_id":"MDEwOlJlcG9zaXRvcnkxMTUyMjkxMzQ=","name":"mdx","full_name":"mdx-js/mdx","owner":{"login":"mdx-js","id":37453691,"node_id":"MDEyOk9yZ2FuaXphdGlvbjM3NDUzNjkx","avatar_url":"https://avatars3.githubusercontent.com/u/37453691?v=4","gravatar_id":"","url":"https://api.github.com/users/mdx-js","html_url":"https://github.com/mdx-js","followers_url":"https://api.github.com/users/mdx-js/followers","following_url":"https://api.github.com/users/mdx-js/following{/other_user}","gists_url":"https://api.github.com/users/mdx-js/gists{/gist_id}","starred_url":"https://api.github.com/users/mdx-js/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mdx-js/subscriptions","organizations_url":"https://api.github.com/users/mdx-js/orgs","repos_url":"https://api.github.com/users/mdx-js/repos","events_url":"https://api.github.com/users/mdx-js/events{/privacy}","received_events_url":"https://api.github.com/users/mdx-js/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/mdx-js/mdx","description":"JSX in Markdown for ambitious projects","fork":false,"url":"https://api.github.com/repos/mdx-js/mdx","forks_url":"https://api.github.com/repos/mdx-js/mdx/forks","keys_url":"https://api.github.com/repos/mdx-js/mdx/keys{/key_id}","collaborators_url":"https://api.github.com/repos/mdx-js/mdx/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/mdx-js/mdx/teams","hooks_url":"https://api.github.com/repos/mdx-js/mdx/hooks","issue_events_url":"https://api.github.com/repos/mdx-js/mdx/issues/events{/number}","events_url":"https://api.github.com/repos/mdx-js/mdx/events","assignees_url":"https://api.github.com/repos/mdx-js/mdx/assignees{/user}","branches_url":"https://api.github.com/repos/mdx-js/mdx/branches{/branch}","tags_url":"https://api.github.com/repos/mdx-js/mdx/tags","blobs_url":"https://api.github.com/repos/mdx-js/mdx/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/mdx-js/mdx/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/mdx-js/mdx/git/refs{/sha}","trees_url":"https://api.github.com/repos/mdx-js/mdx/git/trees{/sha}","statuses_url":"https://api.github.com/repos/mdx-js/mdx/statuses/{sha}","languages_url":"https://api.github.com/repos/mdx-js/mdx/languages","stargazers_url":"https://api.github.com/repos/mdx-js/mdx/stargazers","contributors_url":"https://api.github.com/repos/mdx-js/mdx/contributors","subscribers_url":"https://api.github.com/repos/mdx-js/mdx/subscribers","subscription_url":"https://api.github.com/repos/mdx-js/mdx/subscription","commits_url":"https://api.github.com/repos/mdx-js/mdx/commits{/sha}","git_commits_url":"https://api.github.com/repos/mdx-js/mdx/git/commits{/sha}","comments_url":"https://api.github.com/repos/mdx-js/mdx/comments{/number}","issue_comment_url":"https://api.github.com/repos/mdx-js/mdx/issues/comments{/number}","contents_url":"https://api.github.com/repos/mdx-js/mdx/contents/{+path}","compare_url":"https://api.github.com/repos/mdx-js/mdx/compare/{base}...{head}","merges_url":"https://api.github.com/repos/mdx-js/mdx/merges","archive_url":"https://api.github.com/repos/mdx-js/mdx/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/mdx-js/mdx/downloads","issues_url":"https://api.github.com/repos/mdx-js/mdx/issues{/number}","pulls_url":"https://api.github.com/repos/mdx-js/mdx/pulls{/number}","milestones_url":"https://api.github.com/repos/mdx-js/mdx/milestones{/number}","notifications_url":"https://api.github.com/repos/mdx-js/mdx/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/mdx-js/mdx/labels{/name}","releases_url":"https://api.github.com/repos/mdx-js/mdx/releases{/id}","deployments_url":"https://api.github.com/repos/mdx-js/mdx/deployments","created_at":"2017-12-24T00:01:48Z","updated_at":"2018-09-12T19:55:56Z","pushed_at":"2018-09-12T19:00:02Z","git_url":"git://github.com/mdx-js/mdx.git","ssh_url":"git@github.com:mdx-js/mdx.git","clone_url":"https://github.com/mdx-js/mdx.git","svn_url":"https://github.com/mdx-js/mdx","homepage":"https://mdxjs.com","size":954,"stargazers_count":3919,"watchers_count":3919,"language":"JavaScript","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":120,"mirror_url":null,"archived":false,"open_issues_count":46,"license":{"key":"mit","name":"MIT License","spdx_id":"MIT","url":"https://api.github.com/licenses/mit","node_id":"MDc6TGljZW5zZTEz"},"forks":120,"open_issues":46,"watchers":3919,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/mdx-js/mdx/pulls/257"},"html":{"href":"https://github.com/mdx-js/mdx/pull/257"},"issue":{"href":"https://api.github.com/repos/mdx-js/mdx/issues/257"},"comments":{"href":"https://api.github.com/repos/mdx-js/mdx/issues/257/comments"},"review_comments":{"href":"https://api.github.com/repos/mdx-js/mdx/pulls/257/comments"},"review_comment":{"href":"https://api.github.com/repos/mdx-js/mdx/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/mdx-js/mdx/pulls/257/commits"},"statuses":{"href":"https://api.github.com/repos/mdx-js/mdx/statuses/2442104b9315af934357800e0a7e6a8c68355bab"}},"author_association":"NONE"}}
{"actor":{"display_login":"johno"}}