WKND tutorial - custom component creation error | Community
Skip to main content
New Participant
May 23, 2021
Solved

WKND tutorial - custom component creation error

  • May 23, 2021
  • 2 replies
  • 1782 views

Hello i am trying the custom component creation chapter drom the tutorial but i created the files as instructed but getting the error while installing the package on local aem instance

 

[ERROR] ValidationViolation: "jackrabbit-nodetypes: Node '{}.context [nt:unstructured]' is not allowed as child of node with types '[nt:folder]':
Could not find matching child node definition in parent's node type", filePath=jcr_root\apps\wknd\components\byline\_cq_design_dialog\.context.xml, nodePath=/apps/wknd/components/byline/cq:design_dialog/.context, line=5, column=61
[ERROR] ValidationViolation: "jackrabbit-nodetypes: Node '{}.context [nt:unstructured]' is not allowed as child of node with types '[nt:folder]':
Could not find matching child node definition in parent's node type", filePath=jcr_root\apps\wknd\components\byline\_cq_dialog\.context.xml, nodePath=/apps/wknd/components/byline/cq:dialog/.context, line=5, column=65

 

Please advise

This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.
Best answer by Shivam_S

Seems i made a typing mistake and named the file as .context.xml instead of .content.xml. changing name fixed the issue,

Thanks!

2 replies

Shivam_SAuthorAccepted solution
New Participant
May 23, 2021

Seems i made a typing mistake and named the file as .context.xml instead of .content.xml. changing name fixed the issue,

Thanks!

Asutosh_Jena_
New Participant
May 23, 2021

Hi @shivam_s 

 

What is the jcr:primaryType of all the 3 .content.xml file you have defined?

Ideally the root one should be

jcr:primaryType="cq:Component"

wheras the other 2 i.e. _cq_design_dialog and _cq_dialog should be

jcr:primaryType="nt:unstructured"

Thanks!

Shivam_SAuthor
New Participant
May 23, 2021
Hi the below are the primaryTypes