cal.com icon indicating copy to clipboard operation
cal.com copied to clipboard

Storybook - broken Booker page

Open a0m0rajab opened this issue 2 years ago • 3 comments

Found a bug? Please fill out the sections below. 👍

Issue Summary

when visiting booker it gives an error.

The link: https://ui-rkjl4n59r-cal.vercel.app/?path=/story/atoms-booker--booker&globals=outline:true

Steps to Reproduce

  1. open storybook
  2. go to booker
  3. get the issue

a0m0rajab avatar May 15 '23 22:05 a0m0rajab

Can you please assign this issue to me? Thanks : )

deepak-likes-code avatar May 16 '23 05:05 deepak-likes-code

Hey @a0m0rajab. I'm not able to reproduce the above bug on my local as the Atoms field isn't showing up running yarn dev from apps/storybook folder.

Here is a picture for your reference

Screenshot 2023-05-18 at 3 36 26 PM

deepak-likes-code avatar May 18 '23 10:05 deepak-likes-code

You need to open the atoms booker: image but it's not visible on your side.

Here is a screenshot for reference: image

a0m0rajab avatar May 18 '23 11:05 a0m0rajab

Hello !

@deepak-likes-code, The Booker component relies on the os module, which is not available in the browser environment by default. The webpackFinal configuration for os is set to false in .storybook/main.js, disabling browser compatibility entirely.

That's why Booker.stories.mdx can't render properly ( Not Visible ) .

@PeerRich Disabling all of the Node.js core modules may cause the same issue with other stories, Is there a plan to fix it later?

@a0m0rajab Regarding the useContext error you're facing, it is likely related to TRPC. It appears that the TrpcProvider is missing.

ysfBenali avatar Sep 30 '23 15:09 ysfBenali

thanks @ysfBenali should not it be provided since I am using the default hosted page?

a0m0rajab avatar Sep 30 '23 17:09 a0m0rajab