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

"Module not found: Can't resolve 'subscriptions-transport-ws" when using `apollo-link-ws` #428

nikolasburk opened this Issue Jan 22, 2018 · 5 comments


None yet
6 participants

nikolasburk commented Jan 22, 2018

Intended outcome:

Using apollo-link-ws should be possible without explicitly installing subscriptions-transport-ws.

Actual outcome:

Right now, after installing and using apollo-link-ws in my code, I'm getting the following error in my terminal:

Module not found: Can't resolve 'subscriptions-transport-ws' in '/.../myapp/node_modules/apollo-link-ws/lib'

A workaround is to explicitly install subscriptions-transport-ws (e.g. with yarn add subscriptions-transport-ws)


This comment has been minimized.

muhammad-abubakkar commented Jan 29, 2018

Same issue


This comment has been minimized.

anddoutoi commented Jan 31, 2018

It's an inconvenience I know. But when you ran npm install apollo-link-ws I'm pretty sure you got some output that resembled something like:

npm WARN apollo-link-ws@1.0.4 requires a peer of subscriptions-transport-ws@^0.9.0 but none is installed. You must install peer dependencies yourself.

+ apollo-link-ws@1.0.4
added 1 package in 8.938s

The important part here is: You must install peer dependencies yourself.

The same issue was discussed here and it contains some explanation on why it's listed in peerDependencies.


This comment has been minimized.

supergoat commented Feb 4, 2018

@anddoutoi Is this always going to be the case, or will this be fixed eventually?


This comment has been minimized.

anddoutoi commented Feb 5, 2018

@supergoat I don't know. I'm not a contributor or anything like that. I ended up here cause I had the same issue and accepted that it's a peer dependency and that I hadn't bothered reading what the CLI told me. It's the same with a lot of other stuff, eslint is a peer dependency of all eslint plugins so you always have to install eslint explicitly. I don't know if the question "will this be fixed" even make sense. This is how the eco system works.

@evans evans added the bug label Feb 14, 2018


This comment has been minimized.

deadcoder0904 commented Mar 9, 2018

I think you should close this as its done I guess

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment