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

Temporary fix for having jsx in Storybook8 with one man army package #515

Draft
wants to merge 8 commits into
base: main
Choose a base branch
from

Conversation

isacoder
Copy link
Collaborator

@isacoder isacoder commented Nov 20, 2024

Description

This is a potential temporary fix for the Storybook update to support JSX code in stories.

Since addDecorator was deprecated and the JSX addon does not work without it, this branch implements an alternative solution using a third-party addon: storybook-addon-source.

Considerations on Implementation

  • Since the JSX addon works exclusively with Controls, the example has been updated to use Controls. This example demonstrates the usage with AlertBars only.
  • If we choose to adopt this addon, all component stories will need to be updated to use Controls for compatibility.

Reviewing/Testing steps

Run Storybook with Node 18 or above.
Verify that the Alert Bars story displays correctly with Source information

Screenshot 2024-11-20 at 1 13 46

@isacoder isacoder self-assigned this Nov 20, 2024
Base automatically changed from feature/storybook8-update to main February 19, 2025 05:43
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.

1 participant