Skip to content

Commit

Permalink
move the Mojito.buildInfo before the shared code (#117)
Browse files Browse the repository at this point in the history
  • Loading branch information
allmywant authored Jan 10, 2025
1 parent e70348e commit 088cfc7
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions scripts/cli-build.js
Original file line number Diff line number Diff line change
Expand Up @@ -427,7 +427,11 @@ module.exports = async function build (cliArgs) {
containerData.size.experiments[testId] = buildResult.experiments[testId].size;
}

let sharedCode = targetContents[2];
targetContents.splice(2, 1);

targetContents.push('\nMojito.buildInfo=' + JSON.stringify(containerData) + ';');
targetContents.push(sharedCode);

if (testObjectContents.length) {
targetContents.push(testObjectContents.join('\n'));
Expand Down

0 comments on commit 088cfc7

Please sign in to comment.