In a Community that I am trying to package using 2GP with:
after eliminating several errors I am now getting this one:
These entities are not supported: [NavigationLinkSet]
There is a
CommunityTemplateDefinitionincluded, and that can have a collection of
NavigationLinkSet(according to CommunityTemplateDefinition). But there are no references to
NavigationLinkSetin the source. And we do want to distribute the community template as well as the LWCs and Apex etc.
(There is a
navigationMenuItemwhich look closely related.)
CommunityTemplateDefinitionpackageable? Any suggestions about what the problem is here and how to solve?
Communities are not packageable for 2GP packages.
As an unlocked package yes you can package up the ExperienceBundle (there are some known issues with ExperienceBundle as well on known issue site so do not recommend it as of today) but not as a 2GP yet.
The only recommended way to package communities is via the “Bolt Solution” which allows you to distribute your template. The Bolt solution is done via the org. Check the help article here
Carefully review the limitations of the Managed Package with Bolt Solution, specifically around upgradability. You will note that upgradability is not supported and there is a need for configuration of the Template.
I usually recommend customers to distribute Bolt Solution via a Separate Extension Package because of the limitations around upgradability.