{"action":"reopened","issue":{"url":"https://api.github.com/repos/capaj/systemjs-hot-reloader/issues/95","repository_url":"https://api.github.com/repos/capaj/systemjs-hot-reloader","labels_url":"https://api.github.com/repos/capaj/systemjs-hot-reloader/issues/95/labels{/name}","comments_url":"https://api.github.com/repos/capaj/systemjs-hot-reloader/issues/95/comments","events_url":"https://api.github.com/repos/capaj/systemjs-hot-reloader/issues/95/events","html_url":"https://github.com/capaj/systemjs-hot-reloader/issues/95","id":166047471,"number":95,"title":"Add pattern or callback for deciding which files should trigger a reload","user":{"login":"HydrateEfficiently","id":6957926,"avatar_url":"https://avatars.githubusercontent.com/u/6957926?v=3","gravatar_id":"","url":"https://api.github.com/users/HydrateEfficiently","html_url":"https://github.com/HydrateEfficiently","followers_url":"https://api.github.com/users/HydrateEfficiently/followers","following_url":"https://api.github.com/users/HydrateEfficiently/following{/other_user}","gists_url":"https://api.github.com/users/HydrateEfficiently/gists{/gist_id}","starred_url":"https://api.github.com/users/HydrateEfficiently/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/HydrateEfficiently/subscriptions","organizations_url":"https://api.github.com/users/HydrateEfficiently/orgs","repos_url":"https://api.github.com/users/HydrateEfficiently/repos","events_url":"https://api.github.com/users/HydrateEfficiently/events{/privacy}","received_events_url":"https://api.github.com/users/HydrateEfficiently/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":1,"created_at":"2016-07-18T08:50:11Z","updated_at":"2016-07-18T10:07:56Z","closed_at":null,"body":"I'm using angular as components, and each component is contained in one directory with component.js (angular module), component-controller.js and component.html. I'm running a watch on all my component.html files, and creating a compiled component.html.js (using gulp-angular-templatecache). \r\n\r\nNaturally the hot reloader will handle reloading these scripts and re-bootstrapping the angular page, so I'd like to ignore changes to html files, which, at the moment, cause an unnecessary reload.\r\n\r\nA simple matching callback passed into the HotReloader ctor would do the trick. Takes the filename and checks the result for truthiness to decide whether to do the reload.\r\n\r\ne.g.\r\n\r\n`\r\n_reloader = new HotReloader('http://localhost:5776', {\r\n    match: path => path.endsWith('.js')\r\n};          \r\n`\r\n\r\nLet me know if I'm on the wrong track here. But as far as I could tell there was nothing (in the listener itself, rather than the emitter) that handled this.\r\n\r\nEdit: this is my workaround in the meantime: http://pastebin.com/Jr0e1bqz"}}
{"actor":{"display_login":"HydrateEfficiently"}}