We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent d6fad2a commit 308982bCopy full SHA for 308982b
lib/wpt/index.js
@@ -94,10 +94,16 @@ class WPTUpdater {
94
async updateVersions(updated) {
95
const versionsPath = this.versionsPath;
96
const readmePath = this.readmePath;
97
- const versions = this.getLocalVersions();
+ let versions = this.getLocalVersions();
98
99
this.cli.startSpinner('Updating versions.json ...');
100
Object.assign(versions, updated);
101
+ // Reorder keys alphabetically
102
+ versions = Object.fromEntries(
103
+ Object.entries(versions).sort(([key1], [key2]) =>
104
+ key1.localeCompare(key2)
105
+ )
106
+ );
107
writeJson(versionsPath, versions);
108
this.cli.stopSpinner(`Updated ${versionsPath}`);
109
0 commit comments