Getting Layout Containers in React Components using SPA SDK

Avatar

Avatar

eshoemak

Avatar

eshoemak

eshoemak

17-05-2019

Hi all,

I'm using SPA SDK and adding custom React components to my pages.  That's going great.  I would like to know, has anyone successfully found a way to implement a layout container inside of a React component?  I'm reading through the API @adobe/cq-react-editable-components - npm but not finding it incredibly helpful with this particular situation.

Thanks in advance for any help!

Accepted Solutions (1)

Accepted Solutions (1)

Avatar

Avatar

michaelr8773016

Avatar

michaelr8773016

michaelr8773016

06-08-2019

eshoemak​ - the short answer to your question is yes, you can create a "layout" component in React, we have done so. The actual answer is quite a bit more complex.

I would also agree, the Adobe SPA example doesn't describe the use cases outlined in the best practices of other HTL & Sitely examples. Creating a list or text component is the obvious example, however you cannot build a site from just these components.

Answers (2)

Answers (2)

Avatar

Avatar

kautuk_sahni

Community Manager

Total Posts

5.6K

Likes

962

Correct Answer

1.1K

Avatar

kautuk_sahni

Community Manager

Total Posts

5.6K

Likes

962

Correct Answer

1.1K
kautuk_sahni
Community Manager

16-07-2019

Checking this with SPA expert.

-Kautuk

Avatar

Avatar

ksuayan_shc

Avatar

ksuayan_shc

ksuayan_shc

19-06-2019

Same here. It would be very helpful if documentation on how ModelProvider, Container or ResponsiveGrid React components maybe used in a Route for example.