Debugging when using require.js cache

前端 未结 3 1326
野的像风
野的像风 2021-02-07 03:01

Using require.js I noticed that often the dependencies are cached by the browser and don\'t get updated even if I force the page to completely reload (command+shift+R).

3条回答
  •  日久生厌
    2021-02-07 03:45

    I used

    require.config({ urlArgs: "v=" +  (new Date()).getTime() });
    

    This solved my problem, but you have to remember to remove it, before you goto production.

提交回复
热议问题