Issue with Responsive Grid and Component Visibility After Converting AEM Remote SPA to TypeScript
Hello Everyone,
I recently completed the conversion of our AEM remote Single Page Application (SPA) from JavaScript to TypeScript. However, following the transition, we encountered a couple of issues relating to the responsive grid functionality and component visibility within AEM.
Specifically, when utilizing the <ResponsiveGrid> component in Home.tsx, we encountered an error regarding the pagePath: "Type '{ pagePath: string; itemPath: string; }' is not assignable to type 'IntrinsicAttributes & { title?: string | undefined}'". How can we go about resolving this type assignment issue?
Additionally, although the option to "Drag the Component" remains visible, components added from the AEM side were not appearing on the page. We also received the error message "Component not mapped for resourcetype: ios/components/title", despite having included the necessary import statements for the component.
Interestingly, directly adding the same component (Title) to the home page, as shown in the code snippet below, resulted in both the components – the one added from the responsive grid and the fixed component – becoming visible:
<ResponsiveGrid
pagePath="/content/wknd-app/us/en/home"
itemPath="root/responsivegrid"
/>
<EditableTitle
pagePath="/content/wknd-app/us/en/home"
itemPath="root/title"
/>
I appreciate any insights or suggestions you can provide to help resolve these issues. Thank you!