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

Storybook experiencing CORS issue in Gitpod #21

Open
1 task
Decipher opened this issue Aug 5, 2022 · 5 comments
Open
1 task

Storybook experiencing CORS issue in Gitpod #21

Decipher opened this issue Aug 5, 2022 · 5 comments
Labels
bug Something isn't working

Comments

@Decipher
Copy link
Member

Decipher commented Aug 5, 2022

Describe the bug
While using Storybook in Gitpod we experienced and issue with CORS that breaks all stories.

To Reproduce
Steps to reproduce the behavior: https://gitpod.io/#github.com/druxt/quickstart-druxt-site-tome

  1. Run repository in GitPod:
  2. Create debug content: cd drupal && ddev composer require drupal/devel && ddev drush en devel_generate && ddev drush genc
  3. Run Storybook: cd nuxt && npx nuxt storybook
  4. Look at an Entity story: ?path=/story/druxt-entity-node-article-view-displays--default

Expected behavior

  • No CORs issues, content shows as expected.

Media
If applicable, add screenshots or video to help explain your problem.

Your Environment (please complete the following information):
N/A

Additional context

@Decipher Decipher added the bug Something isn't working label Aug 5, 2022
@miclgael
Copy link

miclgael commented Aug 5, 2022

CleanShot 2022-08-05 at 11 16 27

Cross-Origin Request Blocked: The Same Origin Policy disallows reading the remote resource at https://8080-druxt-quickstartdruxts-ccirmmpsxb1.ws-us59.gitpod.io/jsonapi. (Reason: CORS header ‘Access-Control-Allow-Origin’ missing). Status code: 405.

@Decipher
Copy link
Member Author

Decipher commented Aug 6, 2022

Hi @miclgael,

I just ran a test in a Gitpod instance against this repository and wasn't able to reproduce the issue. I'll try it from a cloned/templated repository to confirm if that's related, but would you be able to send me the repo you experienced this issue in?

@Decipher
Copy link
Member Author

Decipher commented Aug 6, 2022

@miclgael I was also unable to reproduce the issue on a cloned repository. It's very odd, as I witnessed the issue occur during our call but am unable to reproduce.

@miclgael
Copy link

miclgael commented Aug 7, 2022

@Decipher, Spooky!

Maybe it is just my home network. I run a pi-hole so sometimes weird things can happen, though
I've not seen a CORS issue before... 🤔

If you want to check it out anyway - I've forked, committed and pushed to a branch tutorial here:

https://github.com/miclgael/quickstart-druxt-site-tome/tree/tutorial

This was the URL to the gitpod (though I don't know it will work for you.)

@miclgael
Copy link

miclgael commented Oct 9, 2022

Screen Shot 2022-10-10 at 08 34 07

Sorry for the delay @Decipher

This screenshot taken today, following all the same steps, on my same network config. No CORS error.

I think this issue can be closed. Glitch in the matrix perhaps?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants