Skip to content
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

feat: expose publication types for usePublications query #414

Merged
merged 2 commits into from
Jul 12, 2023

Conversation

krzysu
Copy link
Contributor

@krzysu krzysu commented Jul 11, 2023

No description provided.

@changeset-bot
Copy link

changeset-bot bot commented Jul 11, 2023

🦋 Changeset detected

Latest commit: 49f460d

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 3 packages
Name Type
@lens-protocol/react Minor
@lens-protocol/react-web Minor
@lens-protocol/wagmi Major

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@height
Copy link

height bot commented Jul 11, 2023

This pull request has been linked to 1 task:

💡Tip: Add "Close T-13019" to the pull request title or description, to a commit message, or in a comment to mark this task as "Done" when the pull request is merged.

@krzysu krzysu requested a review from desfero July 11, 2023 13:23
value={value}
onChange={(e) => {
if (e.target.checked) {
setPublicationTypes([...publicationTypes, value]);
Copy link
Collaborator

Choose a reason for hiding this comment

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

nit: could be a good use case for js Set given we can't have duplicates in the array (or at least we don't want :D)

Copy link
Contributor Author

Choose a reason for hiding this comment

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

do you mean sth like below? I don't think it's a case here as the value can only be set from a select box, and it can't be checked twice

setPublicationTypes(Array.from(new Set([...publicationTypes, value])));

@krzysu krzysu force-pushed the T-13019/pub-types-use-publications branch from 2cad17d to 49f460d Compare July 12, 2023 12:13
@krzysu krzysu merged commit c8426cb into main Jul 12, 2023
1 check passed
@krzysu krzysu deleted the T-13019/pub-types-use-publications branch July 12, 2023 13:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants