Example code for using components does only render first components
supermueller opened this issue · 1 comments
When following the usage instructions in the readme, the output is not as expected, because only the first vue component will be rendered.
The following code example is not easy to adapt, because of the missing closing tags. If you use the example for in-dom templating, only the first component will be rendered:
<template>
<section>
<prismic-image :field="fields.logo" />
<prismic-rich-text :field="fields.title" />
<prismic-rich-text :field="fields.somethingRich" />
</section>
</template>
To work as in-dom template you have to add the closing tags:
<section>
<prismic-image :field="fields.logo"></prismic-image>
<prismic-rich-text :field="fields.title"></prismic-rich-text>
<prismic-rich-text :field="fields.somethingRich"></prismic-rich-text>
</section>
Although self-closing tags are working in vue-template files (template.vue
), it will be easier for newbies to adapt the example as in-dom templates.
Hey @supermueller, I'm really sorry for the lack of support you got back then, thank you so much though for raising this to our attention. I added a small warning to prevent that 🙂 6bfc2c7