RubyMine’s memory issue

My RubyMine 2016.3 kept consuming too much memory and even ran out of xmx while I was working with TypeScript file. But it’s working pretty smooth when I only need to deal with Ruby code with no TS files opened.

Just randomly, I noticed my global tsc is in the version of 1.8.x but my TS server embed in both Visual Studio Code and RubyMine is upper 2. After I npm install -g TypeScript@2.x.x (forgot the specific version but it’s surely something like 1–2), everything just works well now.

Yea I know… such a random issue and post -.-