Building and viewing storybook causes @qwik-city-sw-register error
Closed this issue · 2 comments
intellix commented
Current Behavior
Build storybook and serve it, you'll get an error that:
Failed to resolve module specifier "@qwik-city-sw-register". Relative references must start with either "/", "./", or "../".
Expected Behavior
Storybook should be browseable even after it has been built. Imagine if you want to deploy all of your components to be browseable for documentation purposes
GitHub Repo
No response
Steps to Reproduce
- Create a new project
npx create-nx-workspace@17.0 --preset=qwik-nx --qwikAppName=myapp
npx nx g qwik-nx:storybook-configuration myapp
npx nx g qwik-nx:component --name=my-component -p myapp --generateStories
- Build and serve your newly built storybook
npx nx run myapp:build-storybook
npx http-server dist/storybook/myapp
- You'll see an error:
Nx Report
Node : 18.18.2
OS : darwin-arm64
npm : 8.19.4
nx : 17.1.3
@nx/js : 17.1.3
@nx/linter : 17.1.3
@nx/eslint : 17.1.3
@nx/workspace : 17.1.3
@nx/cypress : 17.1.3
@nx/devkit : 17.1.3
@nx/eslint-plugin : 17.1.3
@nx/storybook : 17.1.3
@nrwl/tao : 17.1.3
@nx/vite : 17.1.3
typescript : 5.2.2
---------------------------------------
Community plugins:
qwik-nx : 2.0.2
Failure Logs
No response
Additional Information
No response
dmitry-stepanenko commented
fixed by #218