1// Taken from https://github.com/pixeldesu/pixelde.su/blob/main/src/assets/js/modules/vscode.js
2// Adopted by dish
3const editorTargets = document.querySelectorAll("[data-editor-file]");
4editorTargets.forEach((target) => {
5 target.addEventListener("click", (event) => {
6 globalThis.open(
7 `zed://file/${event.currentTarget.dataset.editorFile}`,
8 "_self",
9 );
10 });
11});