How to replace Javascript of production website with local Javascript?

前端 未结 6 2177
礼貌的吻别
礼貌的吻别 2020-12-01 01:41

On my production website, I have compiled Javascript.


It would be very convient for

6条回答
  •  余生分开走
    2020-12-01 02:09

    Though the epascarello's solution works, there is a quicker solution for the minified files debugging. Consider using JavaScript source maps. Modern Firefox and Chrome supports them.

    The idea of source map is to say browser where to find the unminified version. When you start the debugging in your browser developer tools - browser loads unminified version of the script and shows you the easy-to-read JavaScript (or whatever code you compiled to JavaScript) code in the debugger.

提交回复
热议问题