{"action":"created","issue":{"url":"https://api.github.com/repos/ForbesLindesay/browserify-middleware/issues/99","repository_url":"https://api.github.com/repos/ForbesLindesay/browserify-middleware","labels_url":"https://api.github.com/repos/ForbesLindesay/browserify-middleware/issues/99/labels{/name}","comments_url":"https://api.github.com/repos/ForbesLindesay/browserify-middleware/issues/99/comments","events_url":"https://api.github.com/repos/ForbesLindesay/browserify-middleware/issues/99/events","html_url":"https://github.com/ForbesLindesay/browserify-middleware/issues/99","id":181145132,"number":99,"title":"Slow startup time","user":{"login":"mkapnick","id":4642737,"avatar_url":"https://avatars.githubusercontent.com/u/4642737?v=3","gravatar_id":"","url":"https://api.github.com/users/mkapnick","html_url":"https://github.com/mkapnick","followers_url":"https://api.github.com/users/mkapnick/followers","following_url":"https://api.github.com/users/mkapnick/following{/other_user}","gists_url":"https://api.github.com/users/mkapnick/gists{/gist_id}","starred_url":"https://api.github.com/users/mkapnick/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mkapnick/subscriptions","organizations_url":"https://api.github.com/users/mkapnick/orgs","repos_url":"https://api.github.com/users/mkapnick/repos","events_url":"https://api.github.com/users/mkapnick/events{/privacy}","received_events_url":"https://api.github.com/users/mkapnick/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":2,"created_at":"2016-10-05T12:56:22Z","updated_at":"2016-10-15T23:07:31Z","closed_at":null,"body":"Is there a way to speed up the browserify compilation step on startup? \r\n\r\nFor example, when my app makes the first GET request to get the bundle, browserify-middleware goes through the process of compiling and minifying the code into a bundle. All other subsequent requests for this resource are fast, since the bundle has been compiled and is cached.\r\n\r\nSince the first GET request for this resource tries to browserify and minify 10MB of data, my startup time is really slow, close to a minute. How can I make this faster? \r\n\r\nBasically, I may have to abandon this awesome module and compile things offline to avoid a huge delay in startup time. And I'm trying to avoid that."},"comment":{"url":"https://api.github.com/repos/ForbesLindesay/browserify-middleware/issues/comments/254016532","html_url":"https://github.com/ForbesLindesay/browserify-middleware/issues/99#issuecomment-254016532","issue_url":"https://api.github.com/repos/ForbesLindesay/browserify-middleware/issues/99","id":254016532,"user":{"login":"mindeavor","id":17013,"avatar_url":"https://avatars.githubusercontent.com/u/17013?v=3","gravatar_id":"","url":"https://api.github.com/users/mindeavor","html_url":"https://github.com/mindeavor","followers_url":"https://api.github.com/users/mindeavor/followers","following_url":"https://api.github.com/users/mindeavor/following{/other_user}","gists_url":"https://api.github.com/users/mindeavor/gists{/gist_id}","starred_url":"https://api.github.com/users/mindeavor/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mindeavor/subscriptions","organizations_url":"https://api.github.com/users/mindeavor/orgs","repos_url":"https://api.github.com/users/mindeavor/repos","events_url":"https://api.github.com/users/mindeavor/events{/privacy}","received_events_url":"https://api.github.com/users/mindeavor/received_events","type":"User","site_admin":false},"created_at":"2016-10-15T23:07:31Z","updated_at":"2016-10-15T23:07:31Z","body":"- 10mb is quite big for a single bundle. Have you considered bundle splitting?\r\n- In production, browserify-middleware [precompiles on server startup](https://github.com/ForbesLindesay/browserify-middleware#precompile). This is better than, say, waiting for the first GET request.\r\n- If you don't want your website to load at all during compilation, maybe you can try using [the postcompile hook](https://github.com/ForbesLindesay/browserify-middleware#hooks) to wait on port listening until compilation is done."}}
{"actor":{"display_login":"mindeavor"}}