# Polymorphic "resources" whilst maintaining a good authoring experience

**URL:** <https://community.prismic.io/t/polymorphic-resources-whilst-maintaining-a-good-authoring-experience/6394>\
**Category:** Developing with Prismic\
**Created:** [July 26, 2021, 12:09am UTC](https://community.prismic.io/t/polymorphic-resources-whilst-maintaining-a-good-authoring-experience/6394 "2021-07-26T00:09:54Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![paul3](https://dub1.discourse-cdn.com/flex013/user_avatar/community.prismic.io/paul3/32/2234_2.png) [@paul3](https://community.prismic.io/u/paul3)\
**Post date:** [July 26, 2021, 12:09am UTC](https://community.prismic.io/t/polymorphic-resources-whilst-maintaining-a-good-authoring-experience/6394/1 "2021-07-26T00:09:54Z")

</div>

Hello,

- We currently have a blog. It has the traditional setup of a `Post` that can have an `Author` and a `Category`. These are ordered by a `publish date` on a `Post`
- We would like to change this blog to a resources section. By that, I mean that a `Post` might be one type of resource. Other types might be an `eBook`, a `Podcast`, a `Tool` etc. An example would be the resources page at [HubSpot | Business and Marketing Resources](https://www.hubspot.com/resources).
- My immediate thought is that these are different custom types as the fields required and how they present are going to be different - and presenting non-relevant / non-applicable fields to a hypothetical 'resource type' isn't a great experience for the authors.
  - This presents a problem, because as far as I understand, there isn't a way to do a union type / paginate across these multiple types using Gatsby (this is what we're using).

- My second thought is to have a dedicated resource type that simply has publish date and a reference to the applicable custom type (eg. ebook, podcase). This has the somewhat horrible experience of the author then having to publish two pieces of content (the resource and the blog post) to get the content live though.

Is there a way I haven't thought of here? How do I maintain the best authoring experience here?

---

<div class="post-metadata">

**Author:** ![Pau](https://dub1.discourse-cdn.com/flex013/user_avatar/community.prismic.io/pau/32/5422_2.png) [@Pau](https://community.prismic.io/u/Pau)\
**Post date:** [July 27, 2021, 9:02pm UTC](https://community.prismic.io/t/polymorphic-resources-whilst-maintaining-a-good-authoring-experience/6394/3 "2021-07-27T21:02:14Z")

</div>

Hello Paul, thanks for reaching out to the Prismic community

Using [Slices](https://prismic.io/docs/core-concepts/slices) many times is enough to make a Custom Type flexible enough to be reused in different cases. You can save them in the Slice library and reuse them in all types (eBoo, Tool, etc.) and write [Fragments](https://prismic.io/docs/technologies/fragments-gatsby) in your components to make the queries more readable.

You could also use [Content Relationship](https://prismic.io/docs/core-concepts/link-content-relationship) fields to connect one Custom Type to another and access the fields through the query.

It all depends on how specific you need each type to be.

Can you give me more details about your use case?  
And what do you mean about not being able to use Union types?

---

<div class="post-metadata">

**Author:** ![Pau](https://dub1.discourse-cdn.com/flex013/user_avatar/community.prismic.io/pau/32/5422_2.png) [@Pau](https://community.prismic.io/u/Pau)\
**Post date:** [August 3, 2021, 6:07pm UTC](https://community.prismic.io/t/polymorphic-resources-whilst-maintaining-a-good-authoring-experience/6394/4 "2021-08-03T18:07:45Z")

</div>

closed on August 3, 2021, 6:07pm UTC, flag & select 'Something Else' to reopen.

This thread has been closed due to inactivity. [Flag to reopen](https://community.prismic.io/t/re-open-a-thread/2175).

---

<div class="post-metadata">

**Author:** ![system](https://dub1.discourse-cdn.com/flex013/user_avatar/community.prismic.io/system/32/1746_2.png) [@system](https://community.prismic.io/u/system)\
**Post date:** [December 9, 2021, 12:19pm UTC](https://community.prismic.io/t/polymorphic-resources-whilst-maintaining-a-good-authoring-experience/6394/5 "2021-12-09T12:19:57Z")

</div>

Opened on December 9, 2021, 12:19pm UTC


