{"action":"opened","issue":{"url":"https://api.github.com/repos/developit/preact-cli/issues/439","repository_url":"https://api.github.com/repos/developit/preact-cli","labels_url":"https://api.github.com/repos/developit/preact-cli/issues/439/labels{/name}","comments_url":"https://api.github.com/repos/developit/preact-cli/issues/439/comments","events_url":"https://api.github.com/repos/developit/preact-cli/issues/439/events","html_url":"https://github.com/developit/preact-cli/issues/439","id":280440817,"number":439,"title":"Ability to add multiple entrypoints?","user":{"login":"CedarDCX","id":24682090,"avatar_url":"https://avatars3.githubusercontent.com/u/24682090?v=4","gravatar_id":"","url":"https://api.github.com/users/CedarDCX","html_url":"https://github.com/CedarDCX","followers_url":"https://api.github.com/users/CedarDCX/followers","following_url":"https://api.github.com/users/CedarDCX/following{/other_user}","gists_url":"https://api.github.com/users/CedarDCX/gists{/gist_id}","starred_url":"https://api.github.com/users/CedarDCX/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/CedarDCX/subscriptions","organizations_url":"https://api.github.com/users/CedarDCX/orgs","repos_url":"https://api.github.com/users/CedarDCX/repos","events_url":"https://api.github.com/users/CedarDCX/events{/privacy}","received_events_url":"https://api.github.com/users/CedarDCX/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":0,"created_at":"2017-12-08T10:22:25Z","updated_at":"2017-12-08T10:22:25Z","closed_at":null,"author_association":"NONE","body":"**Do you want to request a *feature* or report a *bug*?**\r\nFeature\r\n\r\n**What is the current behavior?**\r\nThere appears to only be one entrypoint: `index.js`\r\n\r\n**If the current behavior is a bug, please provide the steps to reproduce.**\r\nn/a\r\n\r\n**What is the expected behavior?**\r\nAbility to have multiple entrypoints that will be compiled into separate files\r\n\r\n**If this is a feature request, what is motivation or use case for changing the behavior?**\r\nWe're currently using preact-cli primarily for templating and do not need routing and static components in the bundle file. To keep things lean we are looking to generate separate `.js` files to use on pre-rendered built pages, where only the dynamic components we require are output. On other webpack projects we've achieved this by adding an additional entrypoint in the `webpack.config.js` file.\r\n\r\nWe are struggling to achieve something similar using preact-cli. We've tried adding another record to the `config.entry` within `preact.config.js` and whilst the code in our new entrypoint runs on `serve`, it errors on `build`.\r\n\r\nI appreciate our use case is pretty bespoke, but it there any way to add an additional entrypoint that will be generated as is own file on build (whilst maintaining pre-rendering)?\r\n\r\n**Please mention other relevant information.**\r\n- node version - 8.1.4\r\n- npm version - 4.0.5\r\n- Operating system - Windows 10\r\n"}}
{"actor":{"display_login":"CedarDCX"}}