The IDE you know, rebuilt in Rust. IntelliJ IDEA–style keymap, tool windows and search-everywhere in a fast native app: editor, code insight, debugger, Git, terminal, database and HTTP clients for 60+ languages.
TypeScript code-editorcross-platformdapdatabase-clientdebuggerdesktop-appdeveloper-toolsgithttp-clientideintellijlsprusttauriterminal
/** Keeps template stores in step with edits saved by another window (the Settings window). */
import { FILE_TEMPLATES_KEY, reloadFileTemplates } from "./files/store";
import { LIVE_TEMPLATE_OPTIONS_KEY, LIVE_TEMPLATES_KEY, reloadLiveTemplates } from "./live/store";
import { POSTFIX_KEY, reloadPostfixSettings } from "./postfix/store";
const reloaders: Record<string, () => void> = {
[LIVE_TEMPLATES_KEY]: reloadLiveTemplates,
[LIVE_TEMPLATE_OPTIONS_KEY]: reloadLiveTemplates,
[POSTFIX_KEY]: reloadPostfixSettings,
};
export function syncTemplatesFromStorage(): () => void {
const onStorage = (e: StorageEvent) => {
if (!e.key) return;
// File templates also keep per-project schemes under keys extending FILE_TEMPLATES_KEY.
if (e.key.startsWith(FILE_TEMPLATES_KEY)) reloadFileTemplates();
else reloaders[e.key]?.();
};
window.addEventListener("storage", onStorage);
return () => window.removeEventListener("storage", onStorage);
}