Hey - I'm currently building my dream page-builder using your awesome CMS. I was so glad I found the nested docs plugin, which solves so many problems I had in literally every big headless CMS I tried out.
However - I want to hide the automatically generated 'breadcrumbs' field from my nested collection. I tried to use the override function createBreadcrumbsField - as stated in the docs - but it does not seem to work.
Any guidance? Any other way to hide the breadcrumb array field?
Hi! I did this in collection fields
createBreadcrumbsField(
'pages',
{
admin: {
hidden: true,
}
}
),
with this in config:
breadcrumbsFieldSlug: 'breadcrumbs',
Works like a charm!
Hm :/ Doesnt seem to work for me - but thank you for your quick reply. Still get the same error as before.
Okay ... I got it. Had to change the import
From docs:
import createBreadcrumbsField from "@payloadcms/plugin-nested-docs/fields/breadcrumbs";
Path that works for me:
import createBreadcrumbsField from "@payloadcms/plugin-nested-docs/dist/fields/breadcrumbs";
Docs wrong or my setup wrong? 😄
@rzeka with the correct import it worked just like you said - 🙏 thank you
Good. My ide imports what I need itself so I don't focus on those much 😅
Star
Discord
online
Get help straight from the Payload team with an Enterprise License.