{"action":"opened","issue":{"url":"https://api.github.com/repos/ractivejs/ractive/issues/2612","repository_url":"https://api.github.com/repos/ractivejs/ractive","labels_url":"https://api.github.com/repos/ractivejs/ractive/issues/2612/labels{/name}","comments_url":"https://api.github.com/repos/ractivejs/ractive/issues/2612/comments","events_url":"https://api.github.com/repos/ractivejs/ractive/issues/2612/events","html_url":"https://github.com/ractivejs/ractive/issues/2612","id":165689208,"number":2612,"title":"Bug: on-click attribute does not render server-side","user":{"login":"van-nguyen","id":1149825,"avatar_url":"https://avatars.githubusercontent.com/u/1149825?v=3","gravatar_id":"","url":"https://api.github.com/users/van-nguyen","html_url":"https://github.com/van-nguyen","followers_url":"https://api.github.com/users/van-nguyen/followers","following_url":"https://api.github.com/users/van-nguyen/following{/other_user}","gists_url":"https://api.github.com/users/van-nguyen/gists{/gist_id}","starred_url":"https://api.github.com/users/van-nguyen/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/van-nguyen/subscriptions","organizations_url":"https://api.github.com/users/van-nguyen/orgs","repos_url":"https://api.github.com/users/van-nguyen/repos","events_url":"https://api.github.com/users/van-nguyen/events{/privacy}","received_events_url":"https://api.github.com/users/van-nguyen/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":0,"created_at":"2016-07-15T00:45:07Z","updated_at":"2016-07-15T00:45:07Z","closed_at":null,"body":"**Description of the bug:**\r\nIt seems that I am not able to render on-click=\"action\" on server side when the template is already pre-compiled.\r\n\r\n**Versions affected:**\r\n0.7.3\r\n\r\n**Platforms affected:**\r\nLinux\r\n\r\n**Reproduction:**\r\nIt's server side, a jsfiddle won't be able to reproduce.\r\n\r\n**Code:**\r\nRendering as a expressjs engine\r\n```js\r\nlet layout = new Ractive({template: require(build.html.layout)});\r\nconst hbsExt = '.hbs';\r\n\r\napp.engine(hbsExt.substring(1), (filePath, options, callback)=> {\r\n  layout.set(options);\r\n  return callback(null, layout.toHTML());\r\n});\r\n```\r\n\r\nThe precompiled template, the affected part.\r\n```js\r\nside_cat: \r\n   { v: 3,\r\n     t: \r\n      [ { t: 7,\r\n          e: 'a',\r\n          a: \r\n           { href: [ { t: 2, r: 'Url' } ],\r\n             title: [ { t: 2, r: 'Name' } ],\r\n             class: 'mdl-navigation__link' },\r\n          v: { click: 'action' },\r\n          f: [ { t: 2, r: 'Name' } ] } ] } };\r\n```\r\n\r\n<!--\r\nHello!\r\n\r\nThank you for taking your time submitting this issue. To make it easy for everyone to debug, we'll just need a few key pieces of information:\r\n\r\n\r\n\r\nDescription of the bug:\r\nDescribe as much as you can what happened. Include the workarounds you have tried, tools you may have used alongside, build processes and the like.\r\n\r\nVersions affected:\r\nInclude the version of Ractive affected. To ensure that this is not a regression nor has already been fixed in the next version, it is advised to also test the previous versions and next versions.\r\n\r\nPlatforms affected:\r\nInclude the browser or runtime, and if necessary, operating system and device.\r\n\r\nReproduction:\r\nInclude a link to a live specimen of the bug. For your convenience, you can fork the following fiddles:\r\n\r\n    Latest (stable)   : http://jsfiddle.net/fskreuz/geo63339/\r\n    Edge (development): http://jsfiddle.net/fskreuz/kg6na484/\r\n\r\nCode:\r\nIt is advised to include the code in question in the issue. This allows us to have a historical reference of your code should your demo service be offline.\r\n\r\n\r\n\r\nOnce again, thank you for your time and patience.\r\n\r\nRactive Community\r\n\r\n-->\r\n"}}
{"actor":{"display_login":"van-nguyen"}}