Currently, when the project is packaged for HTML, a Utility.js file gets created and is being populated with the content of a few js files coming with the source.
With each packaging, this file gets bigger and bigger as it is appended by AutomationTool.
[Click to see the code in Unreal Engine Github repository][1]
string DestinationFile = OutDir + "/Utility.js";
foreach( var UtilityFile in UtilityJavaScriptFiles)
{
string Data = File.ReadAllText(UtilityFile);
File.AppendAllText(DestinationFile, Data);
}
Content of the file must be cleaned (if exists) before appending.