Comments (32)
Yea, I was using sinopia. Doing a npm set registry https://registry.npmjs.org/
solved the problem.
from storybook.
Great, thank you. This helped:
The solution is to set a registry for modules of specific scope. You can add the following to your project's .npmrc file
@kadira:registry=https://registry.npmjs.org
from storybook.
You can override the registry for specific scopes, if that's the easiest workaround. For example:
npm config set @types:registry https://registry.npmjs.org/
That would tell npm to always get anything for the @types scope directly from the official server on the internet, bypassing Sinopia entirely. Obviously it won't be the right fix for everyone. npm would need internet access (via a proxy if necessary) and there won't be any centralised caching.
from storybook.
Same
from storybook.
First Run:
npm cache clean
Next:
npm rebuild
Cheers!
from storybook.
Setting the registry unfortunately hasn't fixed it for me. :(
$ npm set registry https://registry.npmjs.org/
$ npm i --save-dev @kadira/storybook
npm ERR! Darwin 15.0.0
npm ERR! argv "/usr/local/bin/node" "/usr/local/bin/npm" "i" "--save-dev" "@kadira/storybook"
npm ERR! node v5.10.0
npm ERR! npm v3.8.3
npm ERR! Invalid name: "@kadira/storybook"
Also adding the github url in package.json
leads to the same result.
"@kadira/storybook": "https://github.com/kadirahq/react-storybook.git#v1.1.0"
I suppose, I'm still somehow holding it wrong.
from storybook.
This is a problem for companies that must use private npm proxies, we can't just switch to using global. If there isn't a specific reason for using scopes would appreciate you publishing non-scoped.
Using github repo URL also seems broken with proxies due to the internal scoped dependencies you use:
npm ERR! 404 Registry returned 404 for GET on https://npm-proxy.fury.io/________/@kadira%2fstorybook-ui
from storybook.
Has this issue been fixed? I'm having the same issue as @robin-drexler
from storybook.
You you can get if from the github like this:
"@kadira/storybook": "https://github.com/kadirahq/react-storybook.git"
I had to publish the dist
directory to github in order to enable this.
from storybook.
Thanks @arunoda
That didn't fix my problem but I was able to fix it by explicitly upgrading npm to version 3.8.6
by running npm update npm -g
. Now I can install it correctly with npm i --save-dev @kadira/storybook
.
The version of npm that did not work was 3.8.3
.
I think it was a bug with npm itself.
cc: @robin-drexler
from storybook.
Check this issue as well: #122
from storybook.
Is it possible for you guys to use the official mirror. If not directly install from github.
from storybook.
I hope we are good here. Hope there's nothing we can do for this.
I'll add this into the README, if someone got this error.
from storybook.
For folks that are on npm 2.x I ran into this issue and found that npm 2.15.1
will fail but after upgrading to 2.15.3
everything is working.
from storybook.
Put your auth token into local .npmrc (the .npmrc file inside the repository folder), not into the global one.
//registry.npmjs.org/:_authToken=00000000-0000-0000-0000-000000000000
from storybook.
@gthomas-appfolio that did the trick for me thanks a lot <3
from storybook.
This is a scoped NPM package. I hope that's not available on mirrors yet or something.
from storybook.
@arunoda - Sorry, mind if you explain more of what you mean?
from storybook.
@tedlin182 it seems like you are using fury.io as the NPM mirror.
May be to support private modules.
They seems not support scoped NPM modules. Starting with @.
Just contact them and verify.
As a quick fix, use our github repo URL as the package version. Then it get the module via NPM.
from storybook.
It's great to reopen this since a few people seems to have this issue. Keeping this in the issue list will help them to see this.
from storybook.
Would you consider to publish this as non scoped package?
With the scoped name I cannot use the amazing pnpm substitute of npm project that saves soo much space with creating symlinks instead of having a copy of storybook in each project.
I have 13 packages that use storybook. Each package copies over 500MB and 300.000+ files just because of the storybook. This is hell for the cloud backup and more. Thanks!
from storybook.
We choose scoped packages for a reason to avoid global name collision (ref: the left-pad story). So, we are unlikely to change that.
But, we do realize the pain.
from storybook.
Im having the Invalid name: "@kadira/storybook"
issue.
Same error when I npm i --save-dev @kadira/storybook
or just add it to package.json with "@kadira/storybook": "https://github.com/kadirahq/react-storybook.git"
.
I've tried with node 5.11.1 (npm 3.8.6) and 6.2.2 (npm 3.9.5).
The registry I use is https://registry.npmjs.org/
.
On OS X.
I don't think it's a duplicate of this issue, but issues like #22 is referring to this one.
Any ideas?
from storybook.
Seems like something like this: npm/npm#10344
This will tell me to move this package to something like react-storybook
.
from storybook.
There's nothing we can do about this issue.
from storybook.
Hey, most of the private repositories now supports scoped modules.
Try their docs.
from storybook.
Also, name in pakage.json , should have scope:
"name": "@scope/name"
This help me resolve this issues.
from storybook.
hi
for me npm cache clean
and
npm rebuild
worked
thanks
from storybook.
Just run either of the below commands in terminal
sudo sysctl -w kern.maxfiles=5242880
sudo sysctl -w kern.maxfilesperproc=524288
from storybook.
Initially I tried with "npm set registry https://registry.npmjs.org" (without quotes) and it didnt work. Later I tried with npm set registry https://registry.npmjs.org/ and it worked. "/" MATTERS
from storybook.
Thank you @suhas777 I've updated the first post to match. 👏
from storybook.
@arunoda Thank you very much! You are right, I am use the official mirror.
from storybook.
Related Issues (20)
- [Bug]: Cannot read properties of undefined (reading 'fonts') HOT 3
- [Bug]: Uncaught TypeError: Refresh.isLikelyComponentType is not a function HOT 3
- In @storybook/addon-docs react has been moved from peerDependencies to dependencies HOT 1
- [Bug]: Angular - Wrong detection of standalone components when inheriting
- RollupError: "X" is not exported by "../constants/dist/index.js", imported by "path/file.tsx".
- [Bug]: find-implicit-spies codemod doesn't exist HOT 2
- [Project SfC]: Preview - Error screen adjustments HOT 1
- Could not resolve "./sb-preview/runtime.js" from "iframe.html"
- [Bug]: Cannot find module 'react-dom/client' with portable stories in React 17 projects. HOT 2
- [Bug]: next/font/local is not worked in storybook with vanilla Extract HOT 2
- [Project SfC]: Create the frontend to create a new story file from scratch
- [Bug]: The error message is that there is no default export. HOT 1
- [Bug]: Storybook Server 8.0.8 autodoc error - Element type is invalid
- [Bug]: `useParams` returns null in NextJS 14.2. Storybook 7 & 8 HOT 2
- [Bug]: Deploying to Github Pages is creating `assets/assets` path
- [Bug]: The accessibility scan encountered an error. {"name":"TypeError"} HOT 2
- [Bug]: Module parse failed: Unexpected token HOT 3
- [Bug]: Missing "./dist/react-18" after upgrading storybook to v8 with vitejs v5 HOT 2
- [Project SfC]: Testing
- [Bug]: Storybook doesn't run with tailwindcss in next.js HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from storybook.