Issue: Taxonomy fields with a taxonomyLimit of 1 should not generate an array by default #337

Closed
opened 2026-10-05 02:41:20 +02:00 by adam · 2 comments
Owner

For example, in its current state, this is generated:

category: 
  - After Effects

However, since the limit is 1, most users will not want to iterate through an array to access that object's taxonomy. The following output would make life a ton easier:

category: After Effects

Apologies if there's a way to do this and I'm missing it. I poked around for awhile and couldn't find anything.

For example, in its current state, this is generated: ``` category: - After Effects ``` However, since the limit is 1, most users will not want to iterate through an array to access that object's taxonomy. The following output would make life a ton easier: ``` category: After Effects ``` Apologies if there's a way to do this and I'm missing it. I poked around for awhile and couldn't find anything. <!-- github-sync-id:1377138413 -->
adam closed this issue 2026-10-05 02:41:20 +02:00
Author
Owner

Thanks, @jordanlambrecht, but this causes a field issue as the type goes from an array to a string. Which potentially can break SSGs build process.

Not 100% sure if changing this behavior is the right thing to do. I also verified it with a couple of Hugo sites, and the themes started failing as tags were expecting an array.

image

Thanks, @jordanlambrecht, but this causes a field issue as the type goes from an array to a string. Which potentially can break SSGs build process. Not 100% sure if changing this behavior is the right thing to do. I also verified it with a couple of Hugo sites, and the themes started failing as tags were expecting an array. ![image](https://user-images.githubusercontent.com/2900833/190968658-b8ad5ada-9f69-4a4b-b4eb-c7c4f8a85c12.png) <!-- github-comment-id:1250663274 -->
Author
Owner

For sure! Just wanted to bring up the conversation

For sure! Just wanted to bring up the conversation <!-- github-comment-id:1251320470 -->
Sign in to join this conversation.
No labels
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: adam/vscode-front-matter#337