The-Commit-Company / frappe-react-sdk

React hooks for Frappe
https://frappe-react.vercel.app
MIT License
107 stars 36 forks source link

SDK Dependency Issue #25

Closed tsmanagers closed 1 year ago

tsmanagers commented 1 year ago

When We're trying to install React SDK it shows dependency warning/error for dependent package frappe-js-sdk and socket.io-client, it doesn't stop the install process but at the end it only install React SDK package.

We're trying install on Node 16 through Yarn

@nikkothari22 Can you please help us with this?

nikkothari22 commented 1 year ago

Hi @tsmanagers ,

Frappe React SDK uses both socket.io and frappe-js-sdk internally. When you install frappe-react-sdk, both of those libraries are also installed along with it - they are dependencies so they won't show up in your package.json file. They will show up in your yarn.lock file though.

Thanks.

tsmanagers commented 1 year ago

@nikkothari22 Yes, I know that Frappe React SDK uses the socket.io and frappe-js-sdk internally and it will not show up in package.json file, but it show me inside node_modules folder, right? That's not showing which means it didn't install those dependent packages.

Please kindly help.

nikkothari22 commented 1 year ago

Got it. I think it's because they were added to peerDeps by mistake. Pushing an update that fixes it now.

nikkothari22 commented 1 year ago

@tsmanagers - just released a new version v1.2.1. Installing this version should bring SWR, socket and frappe-js-sdk.

tsmanagers commented 1 year ago

Thanks @nikkothari22 for quick update. Appreciate it.