{"action":"created","comment":{"url":"https://api.github.com/repos/Automattic/wp-calypso/pulls/comments/218700388","pull_request_review_id":156693498,"id":218700388,"node_id":"MDI0OlB1bGxSZXF1ZXN0UmV2aWV3Q29tbWVudDIxODcwMDM4OA==","diff_hunk":"@@ -43,7 +43,14 @@ const getBaseConfig = ( options = {} ) => {\n };\n \n const build = ( target, argv ) => {\n-\tconst config = target.config( { argv, getBaseConfig, calypsoRoot } );\n+\t\tconst targetConfig =target.config( { argv, getBaseConfig, calypsoRoot } );","path":"bin/sdk-cli.js","position":5,"original_position":5,"commit_id":"3c6b51e3a9da3c70f22c4eb97c2283472492afca","original_commit_id":"3c6b51e3a9da3c70f22c4eb97c2283472492afca","user":{"login":"tyxla","id":8436925,"node_id":"MDQ6VXNlcjg0MzY5MjU=","avatar_url":"https://avatars2.githubusercontent.com/u/8436925?v=4","gravatar_id":"","url":"https://api.github.com/users/tyxla","html_url":"https://github.com/tyxla","followers_url":"https://api.github.com/users/tyxla/followers","following_url":"https://api.github.com/users/tyxla/following{/other_user}","gists_url":"https://api.github.com/users/tyxla/gists{/gist_id}","starred_url":"https://api.github.com/users/tyxla/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tyxla/subscriptions","organizations_url":"https://api.github.com/users/tyxla/orgs","repos_url":"https://api.github.com/users/tyxla/repos","events_url":"https://api.github.com/users/tyxla/events{/privacy}","received_events_url":"https://api.github.com/users/tyxla/received_events","type":"User","site_admin":false},"body":"Indentation and spacing is odd here.","created_at":"2018-09-19T07:50:38Z","updated_at":"2018-09-19T07:59:28Z","html_url":"https://github.com/Automattic/wp-calypso/pull/27274#discussion_r218700388","pull_request_url":"https://api.github.com/repos/Automattic/wp-calypso/pulls/27274","author_association":"MEMBER","_links":{"self":{"href":"https://api.github.com/repos/Automattic/wp-calypso/pulls/comments/218700388"},"html":{"href":"https://github.com/Automattic/wp-calypso/pull/27274#discussion_r218700388"},"pull_request":{"href":"https://api.github.com/repos/Automattic/wp-calypso/pulls/27274"}}},"pull_request":{"url":"https://api.github.com/repos/Automattic/wp-calypso/pulls/27274","id":216345285,"node_id":"MDExOlB1bGxSZXF1ZXN0MjE2MzQ1Mjg1","html_url":"https://github.com/Automattic/wp-calypso/pull/27274","diff_url":"https://github.com/Automattic/wp-calypso/pull/27274.diff","patch_url":"https://github.com/Automattic/wp-calypso/pull/27274.patch","issue_url":"https://api.github.com/repos/Automattic/wp-calypso/issues/27274","number":27274,"state":"open","locked":false,"title":"SDK: Can we set output.publicPath?","user":{"login":"sirreal","id":841763,"node_id":"MDQ6VXNlcjg0MTc2Mw==","avatar_url":"https://avatars2.githubusercontent.com/u/841763?v=4","gravatar_id":"","url":"https://api.github.com/users/sirreal","html_url":"https://github.com/sirreal","followers_url":"https://api.github.com/users/sirreal/followers","following_url":"https://api.github.com/users/sirreal/following{/other_user}","gists_url":"https://api.github.com/users/sirreal/gists{/gist_id}","starred_url":"https://api.github.com/users/sirreal/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/sirreal/subscriptions","organizations_url":"https://api.github.com/users/sirreal/orgs","repos_url":"https://api.github.com/users/sirreal/repos","events_url":"https://api.github.com/users/sirreal/events{/privacy}","received_events_url":"https://api.github.com/users/sirreal/received_events","type":"User","site_admin":false},"body":"This is a demonstration PR for multiple assets that may be built from the SDK. There's no way (I know of) to set the publicPath, so any additional assets 404.\r\n\r\n66ee3d9 contains a thorough description:\r\n\r\n> `--outputDir` puts the build output in some location, but if we want to\r\n> split and bundle additional files, webpack doesn't know where to send\r\n> the requests.\r\n> \r\n> For example, `import( './edit' ).then( /* … */ )` will produce a file\r\n> like `0.js` in the location specified by `outputDir`. However, when the\r\n> script is evaluated and the `0.js` chunk is requested, it will only be\r\n> found if it happens to live in the directory corresponding to the\r\n> current route.\r\n> \r\n> Real case:\r\n> \r\n> ```sh\r\n> ./bin/sdk-cli.js gutenberg client/gutenberg/extensions/presets/jetpack \\\r\n> --output-dir=/some-wp-site/wp-content/plugins/jetpack/_inc/blocks\r\n> ```\r\n> \r\n> When we enqueue the script at the correct location, and load\r\n> `/wp-admin/post-new.php`, the `0.js` chunk will 404:\r\n> \r\n> `/wp-admin/0.js -> 404`\r\n> \r\n> If we can specify webpack's `output.publicPath` for the location we know\r\n> the asset will be served from, the chunk can load correctly.\r\n> \r\n> `/wp-content/plugins/jetpack/_inc/blocks/0.js -> 200`\r\n\r\nThen a proof-of-concept code split is applied. With the publicPath from 66ee3d9, this loads well. Otherwise, it's a 404.","created_at":"2018-09-18T15:13:12Z","updated_at":"2018-09-19T07:59:28Z","closed_at":null,"merged_at":null,"merge_commit_sha":"1baae1deb3c6967e1927e6f110e3c2ddfc444a6d","assignee":{"login":"sirreal","id":841763,"node_id":"MDQ6VXNlcjg0MTc2Mw==","avatar_url":"https://avatars2.githubusercontent.com/u/841763?v=4","gravatar_id":"","url":"https://api.github.com/users/sirreal","html_url":"https://github.com/sirreal","followers_url":"https://api.github.com/users/sirreal/followers","following_url":"https://api.github.com/users/sirreal/following{/other_user}","gists_url":"https://api.github.com/users/sirreal/gists{/gist_id}","starred_url":"https://api.github.com/users/sirreal/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/sirreal/subscriptions","organizations_url":"https://api.github.com/users/sirreal/orgs","repos_url":"https://api.github.com/users/sirreal/repos","events_url":"https://api.github.com/users/sirreal/events{/privacy}","received_events_url":"https://api.github.com/users/sirreal/received_events","type":"User","site_admin":false},"assignees":[{"login":"sirreal","id":841763,"node_id":"MDQ6VXNlcjg0MTc2Mw==","avatar_url":"https://avatars2.githubusercontent.com/u/841763?v=4","gravatar_id":"","url":"https://api.github.com/users/sirreal","html_url":"https://github.com/sirreal","followers_url":"https://api.github.com/users/sirreal/followers","following_url":"https://api.github.com/users/sirreal/following{/other_user}","gists_url":"https://api.github.com/users/sirreal/gists{/gist_id}","starred_url":"https://api.github.com/users/sirreal/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/sirreal/subscriptions","organizations_url":"https://api.github.com/users/sirreal/orgs","repos_url":"https://api.github.com/users/sirreal/repos","events_url":"https://api.github.com/users/sirreal/events{/privacy}","received_events_url":"https://api.github.com/users/sirreal/received_events","type":"User","site_admin":false}],"requested_reviewers":[],"requested_teams":[],"labels":[{"id":962633156,"node_id":"MDU6TGFiZWw5NjI2MzMxNTY=","url":"https://api.github.com/repos/Automattic/wp-calypso/labels/DO%20NOT%20MERGE","name":"DO NOT MERGE","color":"b60205","default":false},{"id":967391996,"node_id":"MDU6TGFiZWw5NjczOTE5OTY=","url":"https://api.github.com/repos/Automattic/wp-calypso/labels/[Goal]%20Gutenberg","name":"[Goal] Gutenberg","color":"97f4d2","default":false},{"id":1003342139,"node_id":"MDU6TGFiZWwxMDAzMzQyMTM5","url":"https://api.github.com/repos/Automattic/wp-calypso/labels/[Project]%20SDK","name":"[Project] SDK","color":"b3e4f2","default":false},{"id":285009976,"node_id":"MDU6TGFiZWwyODUwMDk5NzY=","url":"https://api.github.com/repos/Automattic/wp-calypso/labels/[Type]%20Enhancement","name":"[Type] Enhancement","color":"c7def8","default":false},{"id":285009977,"node_id":"MDU6TGFiZWwyODUwMDk5Nzc=","url":"https://api.github.com/repos/Automattic/wp-calypso/labels/[Type]%20Question","name":"[Type] Question","color":"cc317c","default":false}],"milestone":null,"commits_url":"https://api.github.com/repos/Automattic/wp-calypso/pulls/27274/commits","review_comments_url":"https://api.github.com/repos/Automattic/wp-calypso/pulls/27274/comments","review_comment_url":"https://api.github.com/repos/Automattic/wp-calypso/pulls/comments{/number}","comments_url":"https://api.github.com/repos/Automattic/wp-calypso/issues/27274/comments","statuses_url":"https://api.github.com/repos/Automattic/wp-calypso/statuses/3c6b51e3a9da3c70f22c4eb97c2283472492afca","head":{"label":"Automattic:update/conditional-module-load","ref":"update/conditional-module-load","sha":"3c6b51e3a9da3c70f22c4eb97c2283472492afca","user":{"login":"Automattic","id":887802,"node_id":"MDEyOk9yZ2FuaXphdGlvbjg4NzgwMg==","avatar_url":"https://avatars1.githubusercontent.com/u/887802?v=4","gravatar_id":"","url":"https://api.github.com/users/Automattic","html_url":"https://github.com/Automattic","followers_url":"https://api.github.com/users/Automattic/followers","following_url":"https://api.github.com/users/Automattic/following{/other_user}","gists_url":"https://api.github.com/users/Automattic/gists{/gist_id}","starred_url":"https://api.github.com/users/Automattic/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Automattic/subscriptions","organizations_url":"https://api.github.com/users/Automattic/orgs","repos_url":"https://api.github.com/users/Automattic/repos","events_url":"https://api.github.com/users/Automattic/events{/privacy}","received_events_url":"https://api.github.com/users/Automattic/received_events","type":"Organization","site_admin":false},"repo":{"id":45936895,"node_id":"MDEwOlJlcG9zaXRvcnk0NTkzNjg5NQ==","name":"wp-calypso","full_name":"Automattic/wp-calypso","private":false,"owner":{"login":"Automattic","id":887802,"node_id":"MDEyOk9yZ2FuaXphdGlvbjg4NzgwMg==","avatar_url":"https://avatars1.githubusercontent.com/u/887802?v=4","gravatar_id":"","url":"https://api.github.com/users/Automattic","html_url":"https://github.com/Automattic","followers_url":"https://api.github.com/users/Automattic/followers","following_url":"https://api.github.com/users/Automattic/following{/other_user}","gists_url":"https://api.github.com/users/Automattic/gists{/gist_id}","starred_url":"https://api.github.com/users/Automattic/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Automattic/subscriptions","organizations_url":"https://api.github.com/users/Automattic/orgs","repos_url":"https://api.github.com/users/Automattic/repos","events_url":"https://api.github.com/users/Automattic/events{/privacy}","received_events_url":"https://api.github.com/users/Automattic/received_events","type":"Organization","site_admin":false},"html_url":"https://github.com/Automattic/wp-calypso","description":"The JavaScript and API powered WordPress.com","fork":false,"url":"https://api.github.com/repos/Automattic/wp-calypso","forks_url":"https://api.github.com/repos/Automattic/wp-calypso/forks","keys_url":"https://api.github.com/repos/Automattic/wp-calypso/keys{/key_id}","collaborators_url":"https://api.github.com/repos/Automattic/wp-calypso/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/Automattic/wp-calypso/teams","hooks_url":"https://api.github.com/repos/Automattic/wp-calypso/hooks","issue_events_url":"https://api.github.com/repos/Automattic/wp-calypso/issues/events{/number}","events_url":"https://api.github.com/repos/Automattic/wp-calypso/events","assignees_url":"https://api.github.com/repos/Automattic/wp-calypso/assignees{/user}","branches_url":"https://api.github.com/repos/Automattic/wp-calypso/branches{/branch}","tags_url":"https://api.github.com/repos/Automattic/wp-calypso/tags","blobs_url":"https://api.github.com/repos/Automattic/wp-calypso/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/Automattic/wp-calypso/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/Automattic/wp-calypso/git/refs{/sha}","trees_url":"https://api.github.com/repos/Automattic/wp-calypso/git/trees{/sha}","statuses_url":"https://api.github.com/repos/Automattic/wp-calypso/statuses/{sha}","languages_url":"https://api.github.com/repos/Automattic/wp-calypso/languages","stargazers_url":"https://api.github.com/repos/Automattic/wp-calypso/stargazers","contributors_url":"https://api.github.com/repos/Automattic/wp-calypso/contributors","subscribers_url":"https://api.github.com/repos/Automattic/wp-calypso/subscribers","subscription_url":"https://api.github.com/repos/Automattic/wp-calypso/subscription","commits_url":"https://api.github.com/repos/Automattic/wp-calypso/commits{/sha}","git_commits_url":"https://api.github.com/repos/Automattic/wp-calypso/git/commits{/sha}","comments_url":"https://api.github.com/repos/Automattic/wp-calypso/comments{/number}","issue_comment_url":"https://api.github.com/repos/Automattic/wp-calypso/issues/comments{/number}","contents_url":"https://api.github.com/repos/Automattic/wp-calypso/contents/{+path}","compare_url":"https://api.github.com/repos/Automattic/wp-calypso/compare/{base}...{head}","merges_url":"https://api.github.com/repos/Automattic/wp-calypso/merges","archive_url":"https://api.github.com/repos/Automattic/wp-calypso/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/Automattic/wp-calypso/downloads","issues_url":"https://api.github.com/repos/Automattic/wp-calypso/issues{/number}","pulls_url":"https://api.github.com/repos/Automattic/wp-calypso/pulls{/number}","milestones_url":"https://api.github.com/repos/Automattic/wp-calypso/milestones{/number}","notifications_url":"https://api.github.com/repos/Automattic/wp-calypso/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/Automattic/wp-calypso/labels{/name}","releases_url":"https://api.github.com/repos/Automattic/wp-calypso/releases{/id}","deployments_url":"https://api.github.com/repos/Automattic/wp-calypso/deployments","created_at":"2015-11-10T20:00:16Z","updated_at":"2018-09-19T07:20:07Z","pushed_at":"2018-09-19T07:46:22Z","git_url":"git://github.com/Automattic/wp-calypso.git","ssh_url":"git@github.com:Automattic/wp-calypso.git","clone_url":"https://github.com/Automattic/wp-calypso.git","svn_url":"https://github.com/Automattic/wp-calypso","homepage":"https://developer.wordpress.com/calypso/","size":109652,"stargazers_count":10457,"watchers_count":10457,"language":"JavaScript","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":1474,"mirror_url":null,"archived":false,"open_issues_count":1562,"license":{"key":"gpl-2.0","name":"GNU General Public License v2.0","spdx_id":"GPL-2.0","url":"https://api.github.com/licenses/gpl-2.0","node_id":"MDc6TGljZW5zZTg="},"forks":1474,"open_issues":1562,"watchers":10457,"default_branch":"master"}},"base":{"label":"Automattic:master","ref":"master","sha":"07acf332832a999b94912653ccc4ac5dbac00f90","user":{"login":"Automattic","id":887802,"node_id":"MDEyOk9yZ2FuaXphdGlvbjg4NzgwMg==","avatar_url":"https://avatars1.githubusercontent.com/u/887802?v=4","gravatar_id":"","url":"https://api.github.com/users/Automattic","html_url":"https://github.com/Automattic","followers_url":"https://api.github.com/users/Automattic/followers","following_url":"https://api.github.com/users/Automattic/following{/other_user}","gists_url":"https://api.github.com/users/Automattic/gists{/gist_id}","starred_url":"https://api.github.com/users/Automattic/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Automattic/subscriptions","organizations_url":"https://api.github.com/users/Automattic/orgs","repos_url":"https://api.github.com/users/Automattic/repos","events_url":"https://api.github.com/users/Automattic/events{/privacy}","received_events_url":"https://api.github.com/users/Automattic/received_events","type":"Organization","site_admin":false},"repo":{"id":45936895,"node_id":"MDEwOlJlcG9zaXRvcnk0NTkzNjg5NQ==","name":"wp-calypso","full_name":"Automattic/wp-calypso","private":false,"owner":{"login":"Automattic","id":887802,"node_id":"MDEyOk9yZ2FuaXphdGlvbjg4NzgwMg==","avatar_url":"https://avatars1.githubusercontent.com/u/887802?v=4","gravatar_id":"","url":"https://api.github.com/users/Automattic","html_url":"https://github.com/Automattic","followers_url":"https://api.github.com/users/Automattic/followers","following_url":"https://api.github.com/users/Automattic/following{/other_user}","gists_url":"https://api.github.com/users/Automattic/gists{/gist_id}","starred_url":"https://api.github.com/users/Automattic/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Automattic/subscriptions","organizations_url":"https://api.github.com/users/Automattic/orgs","repos_url":"https://api.github.com/users/Automattic/repos","events_url":"https://api.github.com/users/Automattic/events{/privacy}","received_events_url":"https://api.github.com/users/Automattic/received_events","type":"Organization","site_admin":false},"html_url":"https://github.com/Automattic/wp-calypso","description":"The JavaScript and API powered WordPress.com","fork":false,"url":"https://api.github.com/repos/Automattic/wp-calypso","forks_url":"https://api.github.com/repos/Automattic/wp-calypso/forks","keys_url":"https://api.github.com/repos/Automattic/wp-calypso/keys{/key_id}","collaborators_url":"https://api.github.com/repos/Automattic/wp-calypso/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/Automattic/wp-calypso/teams","hooks_url":"https://api.github.com/repos/Automattic/wp-calypso/hooks","issue_events_url":"https://api.github.com/repos/Automattic/wp-calypso/issues/events{/number}","events_url":"https://api.github.com/repos/Automattic/wp-calypso/events","assignees_url":"https://api.github.com/repos/Automattic/wp-calypso/assignees{/user}","branches_url":"https://api.github.com/repos/Automattic/wp-calypso/branches{/branch}","tags_url":"https://api.github.com/repos/Automattic/wp-calypso/tags","blobs_url":"https://api.github.com/repos/Automattic/wp-calypso/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/Automattic/wp-calypso/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/Automattic/wp-calypso/git/refs{/sha}","trees_url":"https://api.github.com/repos/Automattic/wp-calypso/git/trees{/sha}","statuses_url":"https://api.github.com/repos/Automattic/wp-calypso/statuses/{sha}","languages_url":"https://api.github.com/repos/Automattic/wp-calypso/languages","stargazers_url":"https://api.github.com/repos/Automattic/wp-calypso/stargazers","contributors_url":"https://api.github.com/repos/Automattic/wp-calypso/contributors","subscribers_url":"https://api.github.com/repos/Automattic/wp-calypso/subscribers","subscription_url":"https://api.github.com/repos/Automattic/wp-calypso/subscription","commits_url":"https://api.github.com/repos/Automattic/wp-calypso/commits{/sha}","git_commits_url":"https://api.github.com/repos/Automattic/wp-calypso/git/commits{/sha}","comments_url":"https://api.github.com/repos/Automattic/wp-calypso/comments{/number}","issue_comment_url":"https://api.github.com/repos/Automattic/wp-calypso/issues/comments{/number}","contents_url":"https://api.github.com/repos/Automattic/wp-calypso/contents/{+path}","compare_url":"https://api.github.com/repos/Automattic/wp-calypso/compare/{base}...{head}","merges_url":"https://api.github.com/repos/Automattic/wp-calypso/merges","archive_url":"https://api.github.com/repos/Automattic/wp-calypso/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/Automattic/wp-calypso/downloads","issues_url":"https://api.github.com/repos/Automattic/wp-calypso/issues{/number}","pulls_url":"https://api.github.com/repos/Automattic/wp-calypso/pulls{/number}","milestones_url":"https://api.github.com/repos/Automattic/wp-calypso/milestones{/number}","notifications_url":"https://api.github.com/repos/Automattic/wp-calypso/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/Automattic/wp-calypso/labels{/name}","releases_url":"https://api.github.com/repos/Automattic/wp-calypso/releases{/id}","deployments_url":"https://api.github.com/repos/Automattic/wp-calypso/deployments","created_at":"2015-11-10T20:00:16Z","updated_at":"2018-09-19T07:20:07Z","pushed_at":"2018-09-19T07:46:22Z","git_url":"git://github.com/Automattic/wp-calypso.git","ssh_url":"git@github.com:Automattic/wp-calypso.git","clone_url":"https://github.com/Automattic/wp-calypso.git","svn_url":"https://github.com/Automattic/wp-calypso","homepage":"https://developer.wordpress.com/calypso/","size":109652,"stargazers_count":10457,"watchers_count":10457,"language":"JavaScript","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":1474,"mirror_url":null,"archived":false,"open_issues_count":1562,"license":{"key":"gpl-2.0","name":"GNU General Public License v2.0","spdx_id":"GPL-2.0","url":"https://api.github.com/licenses/gpl-2.0","node_id":"MDc6TGljZW5zZTg="},"forks":1474,"open_issues":1562,"watchers":10457,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/Automattic/wp-calypso/pulls/27274"},"html":{"href":"https://github.com/Automattic/wp-calypso/pull/27274"},"issue":{"href":"https://api.github.com/repos/Automattic/wp-calypso/issues/27274"},"comments":{"href":"https://api.github.com/repos/Automattic/wp-calypso/issues/27274/comments"},"review_comments":{"href":"https://api.github.com/repos/Automattic/wp-calypso/pulls/27274/comments"},"review_comment":{"href":"https://api.github.com/repos/Automattic/wp-calypso/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/Automattic/wp-calypso/pulls/27274/commits"},"statuses":{"href":"https://api.github.com/repos/Automattic/wp-calypso/statuses/3c6b51e3a9da3c70f22c4eb97c2283472492afca"}},"author_association":"CONTRIBUTOR"}}
{"actor":{"display_login":"tyxla"}}