Skip to content
This repository was archived by the owner on Nov 19, 2024. It is now read-only.

Conversation

SeanCassiere
Copy link
Contributor

Closes #82
Old PR: #83

operation meta taking an array of tags to allow multiple groupings

meta - tag which took a string has been been renamed to tags which takes an array of strings
update examples to use the new tags prop in operations meta
reintroduce the tag meta prop, giving priority to the tags prop
@SeanCassiere SeanCassiere requested a review from jlalmes July 22, 2022 12:24
@SeanCassiere
Copy link
Contributor Author

SeanCassiere commented Jul 22, 2022

Sure thing, made the change and currently, a test is failing. Will try and fix it and commit it.
Screenshot 2022-07-22 at 6 09 01 PM

Will tag after.

@SeanCassiere
Copy link
Contributor Author

SeanCassiere commented Jul 22, 2022

@jlalmes Houston we have a problem. Things get weird with the nullish coalescing operator.
image
To escape the nested ternaries, will have to introduce if statements as a utility or something to that effect to resolve the Tags.

EDIT: Just realized the first line is covered.

1. let tag;

@jlalmes
Copy link
Contributor

jlalmes commented Jul 22, 2022

This seems to work 👉 tags ?? (tag ? [tag] : undefined)

@SeanCassiere
Copy link
Contributor Author

This seems to work 👉 tags ?? (tag ? [tag] : undefined)

My mathematics teacher would be embarrassed that I forgot about using brackets 😓.

…tion

simplifying nested ternaries for operation meta tags resolution
@SeanCassiere SeanCassiere requested a review from jlalmes July 22, 2022 13:09
Copy link
Contributor

@jlalmes jlalmes left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM - Ship it! ✅

@dodas
Copy link

dodas commented Jul 22, 2022

@jlalmes we originally had tags: string[] instead of tag: string, right?
Just wondering what was the reason to remove it and now reverting it.

@jlalmes
Copy link
Contributor

jlalmes commented Jul 22, 2022

@dodas It was me seeking a "better" DX, because it's very rare that I ever add more than one tag to an endpoint. I suppose having both is a good solution for the time-being.

@SeanCassiere
Copy link
Contributor Author

@jlalmes Squash and Merge? or is there a release pipeline/strategy for this?

@jlalmes
Copy link
Contributor

jlalmes commented Jul 22, 2022

@SeanCassiere squash please! I will manually release after you've merged 👍

@SeanCassiere SeanCassiere merged commit d38c207 into master Jul 22, 2022
@jlalmes
Copy link
Contributor

jlalmes commented Jul 22, 2022

Release under [email protected], thanks for your hard work @SeanCassiere 🚀

@SeanCassiere
Copy link
Contributor Author

Release under [email protected], thanks for your hard work @SeanCassiere 🚀

Thanks a bunch for all your help. Was my second contribution to OSS and y'all made it great.

This was referenced Jul 26, 2022
@jlalmes jlalmes deleted the support-multiple-tags-for-operation branch August 25, 2022 12:04
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

fix/support multiple tags per endpoint
3 participants