Initial commit

This commit is contained in:
Rami Bitar
2026-05-02 09:18:15 -04:00
commit 7348e430c0
96 changed files with 15753 additions and 0 deletions

View File

@@ -0,0 +1,15 @@
const resolveEditorPath = (editorPath: string[] = []) => {
const hasPath = editorPath.length > 0;
const isEdit = hasPath ? editorPath[editorPath.length - 1] === "edit" : false;
return {
isEdit,
path: `/${(isEdit
? [...editorPath].slice(0, editorPath.length - 1)
: [...editorPath]
).join("/")}`,
};
};
export default resolveEditorPath;