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

Fix Storybook Configuration for Windows Development Environment #7904

Merged
merged 1 commit into from
Oct 21, 2024

Conversation

uluckydev
Copy link
Contributor

Description

This PR resolves issue #7903 regarding the Storybook configuration for Windows development environments. Previously, the configuration script generated forward slashes instead of backslashes, leading to errors when running the command npx nx run twenty-front:storybook:serve:dev --configuration=modules on Windows systems.

Changes Made

  • Updated the Storybook configuration to ensure that backslashes are used in file paths for Windows environments, preventing command execution errors.

How to Test

  1. Run Storybook Command:

    • On a Windows machine, execute the command:
      npx nx run twenty-front:storybook:serve:dev --configuration=modules
      
    • Ensure that the command runs successfully without any path-related errors.
  2. Verify Configuration:

    • Check the Storybook configuration files to confirm that paths are using backslashes where applicable.
    • Test the same command on non-Windows environments to verify that there are no regressions.

Related Issue

Copy link

Welcome!

Hello there, congrats on your first PR! We're excited to have you contributing to this project.
By submitting your Pull Request, you acknowledge that you agree with the terms of our Contributor License Agreement.

Generated by 🚫 dangerJS against d889fcb

Copy link
Contributor

@greptile-apps greptile-apps bot left a comment

Choose a reason for hiding this comment

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

PR Summary

This pull request addresses a path handling issue in the Storybook configuration for Windows environments. The changes focus on ensuring consistent path handling across different operating systems.

  • Added 'slash' package as a dependency in package.json for cross-platform path normalization
  • Modified packages/twenty-ui/scripts/generateBarrels.js to use the 'slash' library for consistent forward slash usage in file paths
  • Changes aim to resolve errors when running Storybook on Windows without affecting other environments
  • Fixes issue [🕹️] Path Handling Issue on Windows for Storybook Config #7903 related to path handling in Windows for Storybook configuration

2 file(s) reviewed, no comment(s)
Edit PR Review Bot Settings | Greptile

@charlesBochet
Copy link
Member

@uluckydev Thank you, we do not aim to support Windows developing primarily (we recommend using WSL and use unix path) but I guess this doesn't hurt

@charlesBochet
Copy link
Member

/award 50

Copy link

oss-gg bot commented Oct 21, 2024

Awarding uluckydev: 50 points 🕹️ Well done! Check out your new contribution on oss.gg/uluckydev

@charlesBochet charlesBochet merged commit 5416773 into twentyhq:main Oct 21, 2024
11 checks passed
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.

[🕹️] Path Handling Issue on Windows for Storybook Config
2 participants