Memory leak with Internet Explorer 11 and SPFx

Brass Contributor

Hi all,

 

For a portal project, we are currently developing Web Parts and Extensions components using the SharePoint Framework (1.3.4 version) targeting a communication site. After deployed the application, we experienced a really strange issue with Internet Explorer 11. After browsing few pages (like 10) in normal use, the memory grows up to 1.5GB increasing by 100Mb every time a page is visited! This issue is not present with Chrome and Firefox.

 

First we obviously thought that our code was the problem so we did some experiments to isolate the issue and we've separated each Web Parts to a dedicated bundle and we've loaded them individually on pages. By this way, we've been able to identify some suspicious Web Parts. However, even after commenting the whole code for those suspicious Web Parts, the memory allocation continues to grow even if the Web Part does nothing! We really don't know what could cause this leak.

 

So, my questions are:

  • Does anyone experienced this kind of issues before with IE and SPFx?
  • Can the bundle dependencies cause the leak even if they are not used in the code explicitly?
  • Could it be a related to a know IE polyfill issue coming from SPFx or any know librairies?

Any hints would be appreciated!

 

Our package.json dependencies looks like this:

"dependencies": {
    "@microsoft/sp-core-library": "~1.3.4",
    "@microsoft/sp-lodash-subset": "~1.3.4",
    "@microsoft/sp-webpart-base": "~1.3.4",
    "@types/react": "15.0.38",
    "@types/react-addons-shallow-compare": "0.14.17",
    "@types/react-addons-test-utils": "0.14.15",
    "@types/react-addons-update": "0.14.14",
    "@types/react-dom": "0.14.18",
    "@types/webpack-env": ">=1.12.1 <1.14.0",
    "@types/jquery": "2.0.48",
    "@types/trunk8": "0.0.28",
    "history-events": "^1.0.4",
    "immutability-helper": "2.4.0",
    "lodash-es": "^4.17.4",
    "moment": "^2.18.1",
    "react": "15.4.2",
    "react-dom": "15.4.2",
    "react-js-pagination": "^3.0.0",
    "sp-pnp-js": "~3.0.1",
    "xml2js": "^0.4.19",
    "trunk8": "0.0.1",
    "office-ui-fabric-react": "4.40.2-hotfix.1"
  }

 

6 Replies

Hi Franck, it's not known to us. Would you mind to share your webpart and detailed repro steps for helping us to investigate the issue? You can send private message to me at aaronmi@microsoft.com.

 

Hi @Aaron, I'll see if I can share you the Web Part code for debugging purpose.

 

@Vesa Juvonen @AaronMi

 

Memory leak on modern teamsite, i.e. no custom code running only pure spfx.

Just quickly navigating between "Home" and "Documents" in the left navigation will make memory increase up to about 1400-1500 MB on IE 11, after which the browser stops responding.
 
So this seems to be a problem even on a pure modern page running nothing else.
 
IE version: 11.309.16299.0
Update versions: 11.0.56
 
Also verified on Edge
Microsoft Edge 41.16299.248.0
After navigating between these nodes in left navigation the browser has gone from 400MB of RAM to 3100MB after about 40 navigations
 
No issue on Chrome:
Chrome 64.0.3282.186 (64Bit) remains stable around 880MB<->940MB