acidb / mobiscroll

Cross platform UI controls for progressive web and hybrid apps (plain JS, jQuery, Angular and React)
https://mobiscroll.com
Other
1.54k stars 439 forks source link

Optional platform dependencies #527

Closed AbrahamBrookes closed 2 months ago

AbrahamBrookes commented 2 months ago

There is a known bug in npm with platform dependent optional dependencies: https://github.com/npm/cli/issues/4828

I am coming up against this after installing mobiscroll in my project. We dev in a ubuntu docker and some of our servers are windows, with the windows deployment process running npm install on the server itself.

Due to the above known npm bug, we get errors when deploying mobiscroll to our windows servers. Just wondering if there is anything mobiscroll can/wants to do about this?

dioslaska commented 2 months ago

What is the error exactly? Mobiscroll does not have any platform dependent dependencies, so I'm not sure how is this related to the issue you mentioned.

AbrahamBrookes commented 2 months ago

It comes up out of rollup so I guess I should take it up with them really.

In case anyone else has a similar issue, we ended up adding a line to our deployment script (that runs on the windows server) to install the missing dependency with the --no-save flag so that it does not update our package.json

npm install @rollup/rollup-win32-x64-msvc --no-save