1
0
silverbullet/packages/plugs/draft/draft.ts

8 lines
294 B
TypeScript
Raw Normal View History

2022-04-25 08:33:38 +00:00
import * as clientStore from "@plugos/plugos-silverbullet-syscall/clientStore";
2022-04-24 16:06:34 +00:00
export async function toggleMode() {
let currentValue = !!(await clientStore.get("enableDraftMode"));
console.log("New draft mode", !currentValue);
await clientStore.set("enableDraftMode", !currentValue);
}