{"action":"created","issue":{"url":"https://api.github.com/repos/angular/angular-cli/issues/2569","repository_url":"https://api.github.com/repos/angular/angular-cli","labels_url":"https://api.github.com/repos/angular/angular-cli/issues/2569/labels{/name}","comments_url":"https://api.github.com/repos/angular/angular-cli/issues/2569/comments","events_url":"https://api.github.com/repos/angular/angular-cli/issues/2569/events","html_url":"https://github.com/angular/angular-cli/issues/2569","id":181696668,"number":2569,"title":"Real world usability issues.","user":{"login":"fullstackdave","id":22619746,"avatar_url":"https://avatars.githubusercontent.com/u/22619746?v=3","gravatar_id":"","url":"https://api.github.com/users/fullstackdave","html_url":"https://github.com/fullstackdave","followers_url":"https://api.github.com/users/fullstackdave/followers","following_url":"https://api.github.com/users/fullstackdave/following{/other_user}","gists_url":"https://api.github.com/users/fullstackdave/gists{/gist_id}","starred_url":"https://api.github.com/users/fullstackdave/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/fullstackdave/subscriptions","organizations_url":"https://api.github.com/users/fullstackdave/orgs","repos_url":"https://api.github.com/users/fullstackdave/repos","events_url":"https://api.github.com/users/fullstackdave/events{/privacy}","received_events_url":"https://api.github.com/users/fullstackdave/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":0,"created_at":"2016-10-07T15:20:51Z","updated_at":"2016-10-07T15:22:54Z","closed_at":null,"body":"I love the capabilities that this CLI provides, but it's real world implementation is a nightmare.  Let's say for instance someone has a pre-existing project using A1 with Jade/Pug.  The conversion to A2 is extremely problematic.  Beyond having to gulp your jade/pug into basic html before you build your project, the build process dumps all of it's created files into one directory \"dist\".  From the outside this seems fine, and for some simple implementations of A2 it would be fine.  But for more real world solutions it is very problematic.  First off,  the resulting html and JS files should be able to be relocated (split into different directories) defined by entries in the angular-cli.json.\r\n\r\nMEAN stack project example\r\nIf we point the build to output it's contents to where we can display the resulting HTML '/views/dist', then we cannot access the accompanying .JS bundles.  If we output the contents of the build to our public folders like \"/public/dist\", then our node routing cannot access the HTML.\r\n\r\nSo beyond moving either the JS or HTML results to separate directories manually, this solution doesn't work for us.\r\n\r\nNow beyond that, once you have separated the 2 (HTML & JS Code) it would make things very handy if you could generate an additional HTML file within the build results.  This file would only have the references to the JS bundles say you name it Resouces.html. \r\n\r\nExample \"Resources.html\":\r\n<script type=\"text/javascript\" src=\"/js/custom/location/inline.js\">\r\n<script type=\"text/javascript\" src=\"/js/custom/location/main.4b35c69fe3ac9cc5dbdd.bundle.js\">\r\n\r\nIf you generated the \"Resources.html\" file in the build process, then we could simply include it in our base Jade/Pug starting point and forgo the working with the resulting HTML entirely.\r\n\r\nCurrently, even with all of the shuffling around we are doing our base (app-entry) jade file looks like this.\r\n\r\nblock content\r\n  include index.html\r\n\r\nIf you have further questions or need examples, I would be happy to provide them.\r\n\r\nAll the best,\r\n-d\r\n"},"comment":{"url":"https://api.github.com/repos/angular/angular-cli/issues/comments/252281728","html_url":"https://github.com/angular/angular-cli/issues/2569#issuecomment-252281728","issue_url":"https://api.github.com/repos/angular/angular-cli/issues/2569","id":252281728,"user":{"login":"fullstackdave","id":22619746,"avatar_url":"https://avatars.githubusercontent.com/u/22619746?v=3","gravatar_id":"","url":"https://api.github.com/users/fullstackdave","html_url":"https://github.com/fullstackdave","followers_url":"https://api.github.com/users/fullstackdave/followers","following_url":"https://api.github.com/users/fullstackdave/following{/other_user}","gists_url":"https://api.github.com/users/fullstackdave/gists{/gist_id}","starred_url":"https://api.github.com/users/fullstackdave/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/fullstackdave/subscriptions","organizations_url":"https://api.github.com/users/fullstackdave/orgs","repos_url":"https://api.github.com/users/fullstackdave/repos","events_url":"https://api.github.com/users/fullstackdave/events{/privacy}","received_events_url":"https://api.github.com/users/fullstackdave/received_events","type":"User","site_admin":false},"created_at":"2016-10-07T15:22:54Z","updated_at":"2016-10-07T15:22:54Z","body":"CONTINUATION:  Formatting truncated my comments...\r\n\r\nExample \"Resources.html\":\r\n... assume these are formatted appropriately\r\nsrc=\"/js/custom/location/inline.js\"\r\nsrc=\"/js/custom/location/main.4b35c69fe3ac9cc5dbdd.bundle.js\"\r\n\r\nIf you generated the \"Resources.html\" file in the build process, then we could simply include it in our base Jade/Pug starting point and forgo the working with the resulting HTML entirely.\r\n\r\nCurrently, even with all of the shuffling around we are doing our base (app-entry) jade file looks like this.\r\n\r\nblock content\r\n  include index.html\r\n\r\nIf you have further questions or need examples, I would be happy to provide them.\r\n\r\nAll the best,\r\n-d"}}
{"actor":{"display_login":"fullstackdave"}}