Hey everyone,
I have a problem with the PDF page export in Confluence Cloud.
I am trying to include a Macro in the page export. It works fine when I export the page as a Word document or if I look at it in the page comparison (see screenshot below). But when exporting the page as a PDF I only get „Error loading the extension!“. (Not even the console.log gets triggered.)
The real Macro is build with Custom UI Components. But even with a dummy Macro (build with UI Kit Components only) the PDF export does not work.
Here is my manifest.yml:
modules:
macro:
- key: export-ui-kit-hello-world
function: main
title: export-ui-kit
description: Inserts Hello world!
export:
function: exportMacro
function:
- key: main
handler: index.run
- key: exportMacro
handler: index.exportMacro
And the index.js
import ForgeUI, { render, Fragment, Macro, Text, useProductContext } from "@forge/ui";
const App = () => {
console.log("Hello App!")
return (
<Fragment>
<Text>Hello UI Kit!</Text>
</Fragment>
);
};
export const run = render(
<Macro
app={<App />}
/>
);
const ExportIt = () => {
const productContext = useProductContext();
console.log("product context ", productContext);
return (<Text>Hello Export!</Text>);
};
export const exportMacro = render(<ExportIt />);
Am I the only one facing this problem?
Thanks in advance for your help.
Best regard
Julia