Replies: 1 comment
-
If it were me, I would try to define a fake collection schema, provide the type, and then fill it in the prepare hook |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Hi Folks.
I am trying to create a derived collection from my posts. ie. a collection with less fields while keeping the original intact. For example i need a collection that contains all posts but with only the title and slug fields. i need this to be generated every time i run velite just like other collections. I understand i can augment the collection but i have not seen a way to reduce the number of fields in a collection and generate thus a new collection that will have its own type and schema.
My first though was to make a script that reads the
posts.json
and then generates json files in the same directory but i figured you folks might know a better way to do it :-)Thank you
Beta Was this translation helpful? Give feedback.
All reactions