{"action":"opened","issue":{"url":"https://api.github.com/repos/AjuntamentdeBarcelona/decidim/issues/405","repository_url":"https://api.github.com/repos/AjuntamentdeBarcelona/decidim","labels_url":"https://api.github.com/repos/AjuntamentdeBarcelona/decidim/issues/405/labels{/name}","comments_url":"https://api.github.com/repos/AjuntamentdeBarcelona/decidim/issues/405/comments","events_url":"https://api.github.com/repos/AjuntamentdeBarcelona/decidim/issues/405/events","html_url":"https://github.com/AjuntamentdeBarcelona/decidim/issues/405","id":196943532,"number":405,"title":"Investigate caching behavior in `comments.js`","user":{"login":"josepjaume","id":111746,"avatar_url":"https://avatars.githubusercontent.com/u/111746?v=3","gravatar_id":"","url":"https://api.github.com/users/josepjaume","html_url":"https://github.com/josepjaume","followers_url":"https://api.github.com/users/josepjaume/followers","following_url":"https://api.github.com/users/josepjaume/following{/other_user}","gists_url":"https://api.github.com/users/josepjaume/gists{/gist_id}","starred_url":"https://api.github.com/users/josepjaume/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/josepjaume/subscriptions","organizations_url":"https://api.github.com/users/josepjaume/orgs","repos_url":"https://api.github.com/users/josepjaume/repos","events_url":"https://api.github.com/users/josepjaume/events{/privacy}","received_events_url":"https://api.github.com/users/josepjaume/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":0,"created_at":"2016-12-21T14:18:17Z","updated_at":"2016-12-21T14:18:17Z","closed_at":null,"body":"#### :tophat: User Story\r\nIn order to deal with turbolinks, we had to hack our way to load `comments.js` via `jQuery.getScript`.\r\n\r\nThe first time comments are loaded, the user experiences a slight delay, and that's fine: It's caused by `comments.js` being loaded and *then* loading the actual comments via GraphQL.\r\n\r\n`comments.js` should be cached from then on, drastically reducing the load times. This doesn't seem to be the case though.\r\n\r\nWe should find the way to keep a cached version of the assed so the end-user doesn't pay that price multiple times.\r\n\r\n#### :clipboard: Related documentation\r\nhttps://github.com/AjuntamentdeBarcelona/decidim/blob/master/decidim-comments/app/helpers/decidim/comments/comments_helper.rb#L32\r\n\r\n#### :dart: Acceptance criteria\r\nComments are a bit slower to load the first time, way faster on subsequent requests.\r\n\r\n#### :pushpin: Related issues\r\n*None*\r\n\r\n"}}
{"actor":{"display_login":"josepjaume"}}