I’d like to create multiple subpages using a content adapter and JSON a page resource.
Unfortunately, the content adapter seems to be unable to load the page resource using resources.Get 'data.json'. If the JSON is placed in the global ‘assets’-Folder, it works fine.
Is this a limitation of content adapters?
Yes. I guess this is the chicken and egg problem. You cannot access a page’s resources before it’s created/complete. This is why you get an error if you call site.RegularPages and similar from a content adapter.
You could possibly argue that it should be possible to access the “non content adapter page resources”, but 1. We process content in parallel using all CPU cores and 2. A page isn’t ready to use until we have processed them all, applied cascade front matter etc.
Thanks for the fast reply. I understand that there’s no Schroedinger’s cat. But the information that it’s not possible is surely a nice enhancement for the docs.