{"action":"opened","issue":{"url":"https://api.github.com/repos/BrowserSync/browser-sync/issues/711","labels_url":"https://api.github.com/repos/BrowserSync/browser-sync/issues/711/labels{/name}","comments_url":"https://api.github.com/repos/BrowserSync/browser-sync/issues/711/comments","events_url":"https://api.github.com/repos/BrowserSync/browser-sync/issues/711/events","html_url":"https://github.com/BrowserSync/browser-sync/issues/711","id":93267743,"number":711,"title":"Wrong gulp example?","user":{"login":"MattDiMu","id":8099893,"avatar_url":"https://avatars.githubusercontent.com/u/8099893?v=3","gravatar_id":"","url":"https://api.github.com/users/MattDiMu","html_url":"https://github.com/MattDiMu","followers_url":"https://api.github.com/users/MattDiMu/followers","following_url":"https://api.github.com/users/MattDiMu/following{/other_user}","gists_url":"https://api.github.com/users/MattDiMu/gists{/gist_id}","starred_url":"https://api.github.com/users/MattDiMu/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/MattDiMu/subscriptions","organizations_url":"https://api.github.com/users/MattDiMu/orgs","repos_url":"https://api.github.com/users/MattDiMu/repos","events_url":"https://api.github.com/users/MattDiMu/events{/privacy}","received_events_url":"https://api.github.com/users/MattDiMu/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":0,"created_at":"2015-07-06T12:29:52Z","updated_at":"2015-07-06T12:29:52Z","closed_at":null,"body":"I've integrated browser-sync in my gulp tool chain like this: http://www.browsersync.io/docs/gulp/#gulp-reload. The part I'm questioning is this one:\r\n\r\n```js\r\n// create a task that ensures the `js` task is complete before\r\n// reloading browsers\r\ngulp.task('js-watch', ['js'], browserSync.reload);\r\n```\r\n\r\nBasically gulp is watching the js-directory and this 'js-watch' should be called every time a change is detected. \r\n\r\nThe problem I've experienced is, that this task never ends, looks like browserSync.reload never returns anything (in the command line i never see any 'finished js-watch' information) and the browser therefore reloads only once. Every change after the first one, won't result in any browser reload, as the 'js-watch'-task is still running.\r\n\r\nThe following code fixed this for me:\r\n```js\r\n\tgulp.task('js-watch', ['scripts'], function(){\r\n\t\tbrowserSync.reload();\r\n\t\treturn;\r\n\t});\r\n\r\n```"}}