{"action":"created","issue":{"url":"https://api.github.com/repos/browserify-rails/browserify-rails/issues/101","labels_url":"https://api.github.com/repos/browserify-rails/browserify-rails/issues/101/labels{/name}","comments_url":"https://api.github.com/repos/browserify-rails/browserify-rails/issues/101/comments","events_url":"https://api.github.com/repos/browserify-rails/browserify-rails/issues/101/events","html_url":"https://github.com/browserify-rails/browserify-rails/issues/101","id":98098474,"number":101,"title":"Changes to js file included by require() not reflect when refresh the browser","user":{"login":"superbull","id":455630,"avatar_url":"https://avatars.githubusercontent.com/u/455630?v=3","gravatar_id":"","url":"https://api.github.com/users/superbull","html_url":"https://github.com/superbull","followers_url":"https://api.github.com/users/superbull/followers","following_url":"https://api.github.com/users/superbull/following{/other_user}","gists_url":"https://api.github.com/users/superbull/gists{/gist_id}","starred_url":"https://api.github.com/users/superbull/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/superbull/subscriptions","organizations_url":"https://api.github.com/users/superbull/orgs","repos_url":"https://api.github.com/users/superbull/repos","events_url":"https://api.github.com/users/superbull/events{/privacy}","received_events_url":"https://api.github.com/users/superbull/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":20,"created_at":"2015-07-30T06:50:38Z","updated_at":"2015-11-29T11:21:57Z","closed_at":"2015-11-23T10:37:25Z","body":"I have below file structure:\r\n```\r\n- app\r\n  - assets\r\n    - javascripts\r\n      - application.js\r\n      - foo.js\r\n```\r\n\r\n```javascript\r\n// application.js\r\n\r\n//= require jquery\r\n//= require jquery_ujs\r\n//= require turbolinks\r\n\r\nvar foo = require('./foo');\r\nconsole.log(foo(10));\r\n```\r\n\r\n```javascript\r\n// foo.js\r\n\r\nmodule.exports = function (n) { return n * 10 }\r\n```\r\n\r\nThis works fine at the first time. The console will output:\r\n```\r\n100\r\n```\r\n\r\nThen if I modify the file `foo.js` to\r\n```javascript\r\n// modified foo.js\r\n\r\nmodule.exports = function (n) { return n * 20 }\r\n```\r\nand refresh the browser, the output of the console is the same to the previous one.\r\n\r\nI can make the new code of `foo.js` take effects by doing one of the folloing:\r\n- clear the cache\r\n\r\n    ```bash\r\n    rake tmp:cache:clear\r\n    ````\r\n\r\n- modify `application.js` file, e.g. add a new line, and save the file.\r\n\r\n- add `//= require_tree .` to the `application.js` file, this has a side effect that the `foo.js` file will be included twice.\r\n\r\nIt seems the problem is that the changes to the `foo.js` file is not recognized by the asset pipeline. Is there any settings in browserify-rails to fix this problem?\r\n"},"comment":{"url":"https://api.github.com/repos/browserify-rails/browserify-rails/issues/comments/160403518","html_url":"https://github.com/browserify-rails/browserify-rails/issues/101#issuecomment-160403518","issue_url":"https://api.github.com/repos/browserify-rails/browserify-rails/issues/101","id":160403518,"user":{"login":"gauravtiwari","id":771039,"avatar_url":"https://avatars.githubusercontent.com/u/771039?v=3","gravatar_id":"","url":"https://api.github.com/users/gauravtiwari","html_url":"https://github.com/gauravtiwari","followers_url":"https://api.github.com/users/gauravtiwari/followers","following_url":"https://api.github.com/users/gauravtiwari/following{/other_user}","gists_url":"https://api.github.com/users/gauravtiwari/gists{/gist_id}","starred_url":"https://api.github.com/users/gauravtiwari/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/gauravtiwari/subscriptions","organizations_url":"https://api.github.com/users/gauravtiwari/orgs","repos_url":"https://api.github.com/users/gauravtiwari/repos","events_url":"https://api.github.com/users/gauravtiwari/events{/privacy}","received_events_url":"https://api.github.com/users/gauravtiwari/received_events","type":"User","site_admin":false},"created_at":"2015-11-29T11:21:57Z","updated_at":"2015-11-29T11:21:57Z","body":"@cymen Looks like this issue still exists - tried clearing cache and restarting servers several times and still the same issue. 1.5.0 does work fine though. "}}