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

Add tags to examples and hide those marked as experimental #316

Merged
merged 5 commits into from
Sep 16, 2024

Conversation

reczkok
Copy link
Collaborator

@reczkok reczkok commented Sep 12, 2024

closes #313

Copy link
Collaborator

@iwoplaza iwoplaza left a comment

Choose a reason for hiding this comment

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

Apart from the single nitpick, awesome work! 💚 🐸

Copy link
Collaborator

Choose a reason for hiding this comment

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

I wanted to bring back categories someday, especially when the amount of examples is going to increase, so maybe we could filter the examples as they are being rendered?

        {exampleCategories.map((category) =>
          (examplesByCategory[category.key] ?? []).map((example) => {
            if (example.metadata.tags?.some((tag) => excludeTags.includes(tag))) {
              return null;
            }
            
            return (
              <ExampleLink key={example.key} exampleKey={example.key}>
                {example.metadata.title}
              </ExampleLink>
            );
          }),
        )}

@reczkok reczkok requested a review from iwoplaza September 13, 2024 13:57
Copy link
Collaborator

@iwoplaza iwoplaza left a comment

Choose a reason for hiding this comment

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

( ◦°^°◦) 🌺

@reczkok reczkok merged commit d29f064 into main Sep 16, 2024
2 checks passed
@reczkok reczkok deleted the impr/mark-examples-experimental branch September 16, 2024 08: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.

Create a way to mark examples as experimental, so they do not show up in the final build of the website.
2 participants