-
-
Notifications
You must be signed in to change notification settings - Fork 8.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Predefined tag lists per plugin/preset #5913
Comments
Haha, I just meant are you willing to implement this yourself... Sorry for not making it clear. Go ahead then and we can improve on your PR once it's there. Good luck!😉 |
Also, just as a tip but you'll probably realize as you work on it: we want a tag list per plugin since plugins don't share their tags. It would be cool if they do (IMO) but it's going to be very hard, so just doing it like the blog authors is fine. |
|
Great feature that we indeed need, and gives the opportunity to add extra metadata to each tag in a centralized way. Agree that a config per plugin instance is preferable for now.
We don't have that for blog authors currently, but that makes sense. However, we should rather make this opt-in and add the ability to disable this "security", as mixing inline authors/tags with registered global tags should be allowed. Config can match @Josh-Cena what about implementing this security for blog authors first (simpler), so that we have an example to port this to tags in a consistent way? (I mean, the ability to "prevent" the usage of inline frontmatter authors) |
That sounds good. We also have #5568 which I think should be of high priority as well. I don't have a solid idea of how the Note in the case of authors we started a new API called |
The
Not sure it's a good idea. As a simple site owner, using basic tag strings is enough and I don't necessarily want to customize a tag's description, permalink and whatever we add on this config file.
I'd rather not introduce such CLI unless some users clearly express why it's painful to manually migrate to the new config system, considering the old one will keep working as before. It's a one-step process and should be ok IMHO |
Just an idea but, wouldn't it be useful to allow lists of similar words per line and have resolution to first one? Something like: And if you use infra you get warning saying "use tag 'infrastructure' instead of infra", but if it isn't on the list altogether you get different warning. |
You want to declare tag aliases somehow? and normalize them? Maybe but this can come after if we feel it's useful once we have the basic tags system in place |
Over the long term string tags are not maintainable exactly because of these slight spelling differences. I already stumbled upon this in my ten-post blog. Authors are fine to be repeated on every page, but tags are meant to be used to group posts and are almost certainly reused a lot. Using only a global configuration catches these errors in an early stage. I'd also wish that we can keep the current API for *very* casual users, but we can't have an alternative API without inventing verbose names like |
I am just worried that if you only have list, it promotes the approach of "see the warning about non existing tag? -> Add it to the tags.txt file (or however the tags are stored)". But if you have the list of words you know and some of them are rejected because it is known that the different spelling/different form should be used. It gives users more robust checks. And the implementation is pretty much identical. In terms of Aliases, I wouldn't go as far as creating anything beyond checks. I would just emit warnings / errors saying "you used word infra, which tag system knows about and it prohibits, because the proper replacement is infrastructure". It would be up to user to decide if he wants to create a new tag, or correct the tag to the one suggested by group. |
Sorry to ask so dumbly, but should I still try to self-service or maybe wait until the plan is set? 😊 |
You can go ahead and make an initial example so we have some solid code to discuss on, better than discussing in vacuum |
I hope my question is not too trivial, would you mind poking me to the right direction? |
After some pondering I think a good middleground would be:
|
I'll work on this the plan for now according to previous comments [comment 1, comment 2] is : tags.yml will be in this format : release:
label: release
description: xxx
i18n:
label: i18n
description: xxx
open:
label: Open Source
description: xx
There will be an option There will be an option to configure either ignore warn or error when an unknown tag is used I don't think there is any plans for tag synonyms resolution for now, maybe we'll consider something in the future once this one is finished If there is anything to reconsider in this plan feel free to reply @mambax @Josh-Cena |
Have you read the Contributing Guidelines on issues?
Description
Instead of picking tags for blogs and docs randomly, it would be nice to have a predefined set of tags where the writers can only choose from.
Has this been requested on Canny?
No response
Motivation
To our docs contribute now more than 40 people. They all love tags in docs and blogs. The issue arising is that we have the same tag multiple times, like
API design
Allow a
tags.yml
(or atagsFilePath
) to be assigned to each plugin/preset.tagsFile.yml
Have you tried building it?
No.
Self-service
The text was updated successfully, but these errors were encountered: