3 ms·
Is there a way to configure this with media colocated with posts (i.e., not in a /media folder but in/a/post/subfolder/image.png)?
by flkiwi 3y ago
Is there a way to configure this with media colocated with posts (i.e., not in a /media folder but in/a/post/subfolder/image.png)?
- hunvreus 3y agoBoth the content collections and media can filter by file extension so you could very well have something like: media: input: posts output: /posts categories: [ image ] content: - name: posts label: posts type: collection path: posts fields: - { name: title, label: Title, type: string } - { name: body, label: Body, type: rich-text } The collection of posts will only show the `md` files (that's the default, but you could change it by having a `filename` attribute on your content entry) and the media folder will only show images (`jpg`, `jpeg`, `png`, `gif`, `svg`, `bmp`, `tif`, `tiff`).
- flkiwi 3y agoInteresting. I need to dig into this because this looks like a good solution to my editing dilemma. Thank you for the work, and for the response.