Hi
It depends on how the whole project is packaged
If it is a classic example where you have some index.html (homepage of the game) and inside calls for external JS files
Then when you split that problematic 10.3MB JS file into parts (10 parts or more because the MAX file size for javascript is 1MB on hosting) and in a smart place
then in that idex.html file, it should be
instead of the existing name/call of the problematic JS file (it should be deleted wherever mentioned) a call for 10+ new ones should be placed there
Call in this order:
newJSfile1
(upper part of the code)
and after it
call newJSfile2
(next part of the code)
newJSfile3,4,5,6,
etc…
Why ? the order of loading JS scripts is important
I assume it’s big because it contains a lot of different languages etc. and it’s not minified.
But problems are also possible after you adequately divide the code,
because such things often use base64 encoding inside javascript code
where inside are the calls for certain JS files that some JS code calls or checks, and your two new files will no longer have the NAME/s
that the script is looking for, so it is very possible that you will have to modify a lot of things in JS in addition to index.html…not in one JS file but possibly in several of them… it all depends on how much they talk to each other and additionally with some server where you made the game.
To split javascript code into many JS files try using AI (if possible with some IDE e.g. VS CODE)
Maybe there is an online service for that also…
The only question with such things is whether they will allow you to upload or copy/paste a 10MB code or they will tell you that the max is 1MB