Auto declare the right set of Plasmic components to fetch during getStaticProps

Hi, I’m building a simple NextJS app and using the Headless API. One thing that I found time-consuming/error-prone is declaring the right set of Plasmic components to fetch during getStaticProps. I was wondering if the team was thinking about improvements to this? Ideally I think the goal would be to not need to think about which components to fetch.

One idea that I’ve been playing around with is something similar to extractPlasmicQueryData except it tracks Plasmic components that were initially rendered. Then you simply call a function like autofetchPlasmicComponents in getStaticProps. This solves the problem for most static content, but not for dynamic content. Thoughts on this approach?

Hmm you don’t need an exhaustive list there, only the entrypoints (ones directly used by PlasmicCompoment). Do you often have multiple entrypoints for different pages?

Yeah, it’s common for me to use multiple Plasmic components. For example, say I need to build a complex-ish form. Usually I would create a Page with slots for each input, and my React code would construct the Plasmic input components and add event listeners to them. Do you have alternative approaches to building forms?