Can I open a 10 megabyte javascript file in IntelliJ IDEA or WebStorm without the IDE choking and dying?

Why can't I even edit a 10 megabyte file (.js) in IDEA or Webstorm? I can't even OPEN it. It freezes for several minutes, with one core at 100% and consumes a gigabyte of RAM but does not open my file.

 I need to poke around in a large "bundled but not minified" debug-javascript generated file, to observe order and organization inside the generated file. It's a popular web framework ExtJS (Sencha), and their file is called ext-all-rtl-debug.js.    This is for ExtJS 6, and the file size is 9,417,773 bytes.  The file has 238303 lines.   The file loads and displays fine when inside Google Chrome's dev tools.  Does not appear to be anything special. 

Opening the file with Visual Studio Code (which I expected to choke) succeeds within 3 seconds.  Opening the file within WebStorm with the Sencha ExtJS Plugins, freezes and never opens.   At over 10 minutes and still not open, this is unacceptable.

I can work around this if I disable ALL plugins. Now instead of a freeze-up I get "File size exceeds configured limits".  How am I supposed to bisect and find what is killing the IDE's large file capacity?    Can't the IDE just disable ALL plugin access to expensive large files, if the file is greater than some threshold? 

 If I turn back on the Sencha Plugin, it ironically dies on reading its own large file. Since this plugin is closed source, it's double ironic.

I will enquire about the Source of the badness (the Sencha ExtJS plugin for WebStorm) over on their support,  but it seems to me that the the IDE itself should have some option to detect and auto-disable plugins that freeze thread zero for some unacceptable amount of time, say 5000 milliseconds or more, which I believe the Sencha Plugin is doing.

 I have played around a bit with jps/jstack to try to capture the exact place in the code where the freeze is happening but haven't got too lucky actually figuring out the resulting stack traces as I'm not a Java expert.   I suspect any thread in state RUNNABLE is potentially something "taking a long time", but I don't know how to see what is blocking the UI thread (thread zero I assume).


Comment actions Permalink

Sencha is a third-party plugin JetBrains is not responsible for. Does WebStorm still hang if all plugins except for Sencha are enabled?

There are some ways to speed up processing for large files:


Please sign in to leave a comment.