feat: display shell code exporter at the top

This commit is contained in:
Anoop M D
2024-09-16 00:12:36 +05:30
parent 7dd639192c
commit 3dfb27d447
2 changed files with 9 additions and 1 deletions

View File

@@ -18,6 +18,14 @@ export const getLanguages = () => {
client
}));
allLanguages.push(...languages);
// Move "Shell-curl" to the top of the array
const shellCurlIndex = allLanguages.findIndex(lang => lang.name === "Shell-curl");
if (shellCurlIndex !== -1) {
const [shellCurl] = allLanguages.splice(shellCurlIndex, 1);
allLanguages.unshift(shellCurl);
}
}
return allLanguages;
};