{"action":"closed","issue":{"url":"https://api.github.com/repos/angular/universal/issues/691","repository_url":"https://api.github.com/repos/angular/universal","labels_url":"https://api.github.com/repos/angular/universal/issues/691/labels{/name}","comments_url":"https://api.github.com/repos/angular/universal/issues/691/comments","events_url":"https://api.github.com/repos/angular/universal/issues/691/events","html_url":"https://github.com/angular/universal/issues/691","id":220403592,"number":691,"title":"Access route with segments via the server.","user":{"login":"joaogarin","id":2866604,"avatar_url":"https://avatars1.githubusercontent.com/u/2866604?v=4","gravatar_id":"","url":"https://api.github.com/users/joaogarin","html_url":"https://github.com/joaogarin","followers_url":"https://api.github.com/users/joaogarin/followers","following_url":"https://api.github.com/users/joaogarin/following{/other_user}","gists_url":"https://api.github.com/users/joaogarin/gists{/gist_id}","starred_url":"https://api.github.com/users/joaogarin/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/joaogarin/subscriptions","organizations_url":"https://api.github.com/users/joaogarin/orgs","repos_url":"https://api.github.com/users/joaogarin/repos","events_url":"https://api.github.com/users/joaogarin/events{/privacy}","received_events_url":"https://api.github.com/users/joaogarin/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":5,"created_at":"2017-04-08T14:38:35Z","updated_at":"2017-10-10T19:34:32Z","closed_at":"2017-10-10T19:34:32Z","author_association":"NONE","body":"* **I'm submitting a ...**\r\n- [X ] bug report\r\n\r\n* **What modules are related to this Issue?**\r\n- [ X] express-engine\r\n\r\n* **Do you want to request a *feature* or report a *bug*?**\r\n\r\nReporting a possible bug\r\n\r\n* **What is the current behavior?**\r\n\r\nCurrently when accessing a route with the following setup : \r\n\r\n```\r\nroute/:id\r\n```\r\n\r\nExpress actually fires multiple requests to some assets like \r\n\r\n```\r\nGET: /spot/1: 0.670ms\r\nGET: /spot/styles.css: 0.254ms\r\nGET: /spot/client.js: 0.365ms\r\n```\r\n\r\nThis is ofc not correct as only the first one should be issued. I dont know exactly what causes these requests to fire. My app is based on https://github.com/FrozenPandaz/ng-universal-demo\r\n\r\n* **If the current behavior is a bug, please provide the steps to reproduce and if possible a minimal demo of the problem** by creating a github repo.\r\n\r\n1 ) Setup a route in both client and server that has a segment like 'route:id'\r\n2 ) Access the route directly (via server as in the client it all works fine)\r\n3 ) See multiple GET requests being fired for several routes like mentioned previously.\r\n\r\n* **What is the expected behavior?**\r\n\r\nOnly a GET request for route/1 (or whatever id is given) should be issued.\r\n\r\n* **Please tell us about your environment:**\r\n\r\n- Angular version: 4.0\r\n- Browser: [all]\r\n- Language: [TypeScript 2.2.1 ]\r\n- OS:  [Mac OS X]\r\n- Platform: [NodeJs]\r\n\r\n* **Other information** (e.g. detailed explanation, stacktraces, related issues, suggestions how to fix, links for us to have context, eg. stackoverflow, gitter, etc)\r\n\r\nThis is the logging I get when accessing this route : \r\n\r\n```\r\nGET: /spot/1: 0.670ms\r\nGET: /spot/styles.css: 0.254ms\r\nGET: /spot/client.js: 0.365ms\r\n```\r\n\r\nwhen accessing http://localhost:8080/spot/1\r\nroute code for express looks like this :\r\n\r\n```javascript\r\nROUTES.forEach(route => {\r\n  app.get(route, (req, res) => {\r\n   console.time(`GET: ${req.originalUrl}`);\r\n      res.render('../dist/index', {\r\n        req: req,\r\n        res: res\r\n      });\r\n      console.timeEnd(`GET: ${req.originalUrl}`);\r\n  });\r\n});\r\n```\r\n\r\nThis is how the routes are configured in my app : \r\n\r\n```javascript\r\nexport const ROUTES: string[] = [\r\n  '/',\r\n  '/explore',\r\n  '/auth',\r\n  '/spot/:id',\r\n];\r\n```"}}
{"actor":{"display_login":"Toxicable"}}