Uploaded image for project: 'ZK'
  1. ZK
  2. ZK-5057

minified JS code contains added polyfill functions

XMLWordPrintable

    • None

      Steps to Reproduce

      compare the typescript compile results
      e.g.
      web/js/zk/ext/jquery.js vs web/js/zk/ext/jquery.src.js
      or
      web/js/zul/Widget.js vs web/js/zul/Widget.src.js

      ... several more

      Current Result

      the minified production version contains additional (repeated) polyfill code
      starting with:
      var $jscomp=$jscomp||{};$jscomp.scope={};$jscomp.checkStringArgs=function(g,h,e)...

      This extra code doesn't exist in the NON minified debug versions ... so it seems unnecessary, especially it's unexpected to add code during minification.

      Expected Result

      No additional repeated code in minified versions.
      Only one definition of required polyfilled functions.

      Debug Information

      This additional code also conflicts with external JS libraries such as https://materializecss.com/ making an integration seem to work in debug mode but then fail during production (IE11 which actually runs the code)

      Workaround

            jumperchen jumperchen
            cor3000 cor3000
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated:
              Resolved: