Skip to content

Commit

Permalink
feat(app-page-builder): add debug utilities
Browse files Browse the repository at this point in the history
  • Loading branch information
Pavel910 committed Apr 2, 2024
1 parent fd6e246 commit 9a677ac
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,13 @@ import { Layout } from "./Layout";
import { Elements as BaseElements } from "~/editor/config/Elements";
import { Element as BaseElement, ElementProps as BaseElementProps } from "~/editor/config/Element";
import { createGetId } from "~/editor/config/createGetId";
import { useDebugUtilities } from "~/editor/useDebugUtilities";

const SCOPE = "content";

const BaseContent = makeDecoratable("EditorContent", () => {
useDebugUtilities();

return (
<Layout>
<Elements />
Expand Down
2 changes: 1 addition & 1 deletion packages/app-page-builder/src/editor/useDebugUtilities.ts
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ export const useDebugUtilities = () => {
};

// @ts-expect-error This function is for debugging purposes!
window["debug_printPageContent"] = () => {
window["debug_printDocumentContent"] = () => {
getRawElementTree().then(tree => {
console.log(tree);
});
Expand Down

0 comments on commit 9a677ac

Please sign in to comment.