Documentation work. Add command info for all Utility plugin commands.

This commit is contained in:
Dragory 2019-10-25 23:14:21 +03:00
parent d9b65590d8
commit 9b5307ba2b
5 changed files with 197 additions and 52 deletions

View file

@ -34,6 +34,15 @@ export const DocsStore: Module<DocsState, RootState> = {
if (state.plugins[name]) return;
const data = await get(`docs/plugins/${name}`);
if (data && data.commands) {
data.commands.sort((a, b) => {
const aName = a.trigger.toLowerCase();
const bName = b.trigger.toLowerCase();
if (aName > bName) return 1;
if (aName < bName) return -1;
return 0;
});
}
commit("setPluginData", { name, data });
},
},